Accept terms and conditions
Record acceptance of the currently-in-effect terms and privacy version for this account. All three consents must be true or the request is a 400. Requires a read_write key.
POST
/api/v1/tnc/acceptRequest body
Section titled “Request body”| Field | Type | Required | Description |
|---|---|---|---|
accept_house_rules |
boolean,null | no | Acceptance of the house rules. Defaults to accept_terms AND accept_privacy when omitted. |
accept_privacy |
boolean | yes | Acceptance of the privacy policy. Must be true. |
accept_terms |
boolean | yes | Acceptance of the terms of use. Must be true. |
device_id |
string | yes | Identifier for the device recording the acceptance. |
Responses
Section titled “Responses”| Status | Description | Schema |
|---|---|---|
200 |
Success | object |
400 |
A parameter was missing or invalid. | Error |
401 |
Missing, malformed or unrecognized signature, or a timestamp outside the 30-second window. Body: {“error”:“Missing or invalid API key credentials”} | Error |
403 |
This API key does not have write access. The account behind this key is not active, for example it is pending approval or suspended. Body: {“error”:“Your account is suspended. Contact support.”}, the message naming the account’s status. | Error |
422 |
The acceptance was not recorded: no terms are in effect, the terms changed since you read them, or a consent value was refused. The body’s error says why. |
Error |
Example
Section titled “Example”Request:
curl --request POST \ --url 'https://demo.stxapp.io/api/v1/tnc/accept' \ --header 'X-STX-ACCESS-KEY: <key-id>' \ --header 'X-STX-ACCESS-TIMESTAMP: <unix-ms>' \ --header 'X-STX-ACCESS-SIGNATURE: <base64-ed25519>' \ --header 'Content-Type: application/json' \ --data '{ "accept_house_rules": true, "accept_privacy": true, "accept_terms": true, "device_id": "my-device-001"}'Response 200:
{ "message": "string"}Response fields
Section titled “Response fields”| Field | Type | Description |
|---|---|---|
message |
string | Always "Success" when the acceptance was recorded. |

