Skip to content

Commit

Permalink
Update docs for new privacy policy info API (#355)
Browse files Browse the repository at this point in the history
  • Loading branch information
PJB3005 authored Dec 8, 2024
1 parent b5dc815 commit e384088
Show file tree
Hide file tree
Showing 2 changed files with 54 additions and 1 deletion.
43 changes: 43 additions & 0 deletions src/en/general-development/setup/server-hosting-tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,49 @@ name = "wizards_den_us_west"
# password = ""
```

### Privacy Policy

```admonish failure "This is not legal advice"
This functionality and documentation is provided on a best-effort basis **only**. We intend to make it as easy as possible for server hosts to comply with legal requirements, but nothing here is a replacement for talking with a real lawyer if it comes down to it.
```

The launcher has the capability of presenting a privacy policy prompt when a player tries to connect to your server, if configured. This is likely desirable for all major servers.

How it works: the game server provides three parameters that the launcher will check as early as possible in the connection handshake:

* Link: a link to a HTTP(S) URL where your privacy policy is hosted.
* Identifier: a unique value that identifies a specific server group's privacy policy, to unambiguously distinguish it.
* Version: a unique value that identifies a version of your privacy policy, to allow recognizing changes.

To configure this, you should configure the following three CVars in your configuration:

```toml
[status]
privacy_policy_link = "https://example.com/privacy"
# Set this to a unique value for your server community.
# DO NOT COPY PASTE THIS.
privacy_policy_identifier = "example_server_identifier"
# This can be anything, but a date may be the most humanly meaningful.
# Change it every time you update your privacy policy!
privacy_policy_version = "2024-11-30"
```

#### Details

```admonish info
This section is provided to help you best understand how the launcher interacts with your game server while this feature is enabled.
```

When a player first connects to your server with this system enabled, they will be prompted with a link to the privacy policy and the ability to accept or decline it.

* If they click the link, the privacy policy linked will open in their browser.
* If they click accept, the launcher will continue with normal connection procedures (downloading resources, starting client, connecting to game server, etc...)
* If they click decline, the connection is aborted immediately. In this scenario, no further contact with your server will have happened than a single `HTTP GET` of the `/info` server API endpoint.

If they click accept, the consent (based on identifier and version) is saved into the launcher's database and they will not be re-prompted again later.

If you change your version parameter later, players will be prompted again by the same dialog, although with different text clearly indicating that your privacy policy has been updated since they last accepted it.

## Troubleshooting

### Unable to advertise to hub / people cannot connect
Expand Down
12 changes: 11 additions & 1 deletion src/en/robust-toolbox/server-http-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,17 @@ More detailed JSON server information that is mostly necessary when connecting t
"icon": "discord", // Icon to use for this button, can be left out. See below for valid icon names.
"url": "https://discord.gg/abcdef" // Link this button opens when pressed. Must be http:// or https://
}
]
],
// Optional, specifies information about a privacy policy that players must agree with.
"privacy_policy": {
// Link that contains the privacy policy, accessible via web browser.
"link": "https://example.com/privacy",
// An identifier that will be stored by the launcher when accepted.
// THIS SHOULD BE UNIQUE FOR EVERY SERVER COMMUNITY. DON'T JUST COPY PASTE THIS FROM SOMEBODY ELSE.
"identifier": "example",
// The "version" of the privacy policy. This should be changed if the server's privacy policy has been updated.
"version": "example"
}
}
```

Expand Down

0 comments on commit e384088

Please sign in to comment.