State where one of your customers is
/api/v1/users/{id}/jurisdictionWHERE YOU SAY YOUR CUSTOMER IS. You ran the KYC, you hold the licence, so the assertion is yours and Parity records and applies it. Parity does not authenticate your end users and does not geolocate them: nothing here is a lookup.
A country as ISO 3166-1 alpha-2, optionally with the part of an ISO 3166-2 code after the hyphen for a country whose sub-national treatment differs. The SHAPE is validated and the value is not, because a list of permitted countries would go stale and a country missing from it would be silently unassertable.
This is separate from the region on an embed session, which ranks a board and whose vocabulary includes things that are not countries.
It changes nothing until you switch jurisdiction enforcement on. Assertions are recorded either way, so you can populate them, read back how often they disagree with the country we observe, and only then enforce.
An assertion REPLACES the whole pair rather than merging into it: send the subdivision again, or send null to go back to country level.
Storing this does not make anybody compliant anywhere. It is a fact you supplied, applied against a rulebook you wrote.
Header parameters
x-parity-operatorstringoptionalFor an aggregator: the operator this request is for, one of your direct child operators, by its id or its slug (
GET /api/v1/operators/childrenlists them). Omit it, or name yourself, to act as yourself. A key may act only for a direct child in the same mode as its own operator; anything else is403 operator_not_permittedor403 mode_mismatch, and an unknown name answers exactly like an operator that is not yours.
Path parameters
idstringrequired
Bodyapplication/json
countrystringrequiredmin length 2 · max length 2 · example: "MT"
subdivisionstring · nullableoptionalmax length 3 · example: "NY"
Responses
- 200application/json
Stored, and echoed back normalised rather than as sent.
Show response fieldsHide response fields
userIdstringoptionaljurisdictionobjectoptionalShow propertiesHide properties
countrystringoptionalsubdivisionstring · nullableoptional
assertedAtstringoptionalformat: date-time
- 400application/json · Error
The country was not a two-letter code, the body did not parse as JSON, or the
{id}in the path was empty.Codes:
invalid_json,invalid_request,invalid_jurisdiction,missing_user.Show response fieldsHide response fields
errorstringrequiredMachine-readable code.
messagestringoptionaldetailanyoptionalPresent on validation failures and some refusals.
requiredstring | arrayoptionalOn
insufficient_scope: the scope this key needs. A single scope from the key gate; an array of every scope the call needs fromPOST /embed-sessionsandDELETE /embed-sessions/{id}.acceptedScopesstring[]optionalOn
insufficient_scopefrom a route that accepts any one of several scopes (the player limit, status, statement and audit routes): every scope that would pass.requiredis still the first of them.missingstring[]optionalOn
insufficient_scopefromPOST /embed-sessionsorDELETE /embed-sessions/{id}: the required scopes this key does not carry.supportedanyoptionalThe values that would have been accepted. On
invalid_typefromGET /reconciliation/feedand from both player activity feeds: the known item types, as an array of strings. Onstake_exceeds_available_depththe figure issupportedStakeinstead.statestring · nullableoptionalOn the refusals of
POST /orders/{id}/cancelandPOST /orders/{id}/confirm-reserve: the order's execution state when it was refused, or null for an unknown order.transmissionStatestring · enumoptionalOn the refusals of
POST /orders/{id}/cancel.unknownmeans keep holding the authorization;resolvedmeans the order's ownoperatorMoneyalready says what to apply.Possible values:
not_transmittedunknownresolvedearlieststringoptionalOn
updated_since_too_oldfrom the player activity feeds: the earliest instant the feed can answer from.format: date-time
noOrderForKeybooleanoptionalOn
quote_not_found,quote_expiredanduser_suspendedfromPOST /api/v1/orders: proof that no earlier request under thisclientOrderIdplaced an order.queuedbooleanoptionalOn
503 order_in_progress: this request was never run, because Parity was too busy to start it. Resend it unchanged.retryAfterSecondsnumberoptionalOn every
rate_limited: seconds until the window resets.Retry-Aftercarries the same figure.retryAfterMsnumberoptionalOn
over_tenant_exposure: milliseconds until the exposure window rolls over.maxStakenumberoptionalOn
over_wager_limitandstake_exceeds_stale_limit: the largest stake, in major units, that would be accepted.maxCentsnumberoptionalOn
line_not_available: the executable price, in cents, that put the line outside the wagerable band. A price, not an amount of money.requestedStakenumberoptionalOn
stake_exceeds_available_depth: the stake you asked for.supportedStakenumberoptionalOn
stake_exceeds_available_depth: the largest stake the book can fill at these terms. Re-quote at it to accept.orderIdstringoptionalOn
quote_already_usedandidempotency_conflictfromPOST /api/v1/orders: seeOrderConflict.executionRefstringoptionalOn a
POST /api/v1/ordersrefusal that closed an order Parity had already recorded (rejected,reconciliation_required,insufficient_collateral,insufficient_position): that order’s Parity execution reference. Quote it to Parity support.detailnever quotes a venue order id; this reference stands in for one.sellableContractsnumberoptionalOn
insufficient_positionandbelow_venue_minimumfrom a live cash out quote: the most contracts this customer could sell now, on the hundredth-of-a-contract grid.minimumContractsnumberoptionalOn the same two refusals: the smallest sale, in contracts, this market accepts.
- 401application/json · Error
The key is absent, unrecognised or revoked. Waiting does not help.
Codes:
missing_credentials,invalid_key,revoked_key.Show response fieldsHide response fields
errorstringrequiredMachine-readable code.
messagestringoptionaldetailanyoptionalPresent on validation failures and some refusals.
requiredstring | arrayoptionalOn
insufficient_scope: the scope this key needs. A single scope from the key gate; an array of every scope the call needs fromPOST /embed-sessionsandDELETE /embed-sessions/{id}.acceptedScopesstring[]optionalOn
insufficient_scopefrom a route that accepts any one of several scopes (the player limit, status, statement and audit routes): every scope that would pass.requiredis still the first of them.missingstring[]optionalOn
insufficient_scopefromPOST /embed-sessionsorDELETE /embed-sessions/{id}: the required scopes this key does not carry.supportedanyoptionalThe values that would have been accepted. On
invalid_typefromGET /reconciliation/feedand from both player activity feeds: the known item types, as an array of strings. Onstake_exceeds_available_depththe figure issupportedStakeinstead.statestring · nullableoptionalOn the refusals of
POST /orders/{id}/cancelandPOST /orders/{id}/confirm-reserve: the order's execution state when it was refused, or null for an unknown order.transmissionStatestring · enumoptionalOn the refusals of
POST /orders/{id}/cancel.unknownmeans keep holding the authorization;resolvedmeans the order's ownoperatorMoneyalready says what to apply.Possible values:
not_transmittedunknownresolvedearlieststringoptionalOn
updated_since_too_oldfrom the player activity feeds: the earliest instant the feed can answer from.format: date-time
noOrderForKeybooleanoptionalOn
quote_not_found,quote_expiredanduser_suspendedfromPOST /api/v1/orders: proof that no earlier request under thisclientOrderIdplaced an order.queuedbooleanoptionalOn
503 order_in_progress: this request was never run, because Parity was too busy to start it. Resend it unchanged.retryAfterSecondsnumberoptionalOn every
rate_limited: seconds until the window resets.Retry-Aftercarries the same figure.retryAfterMsnumberoptionalOn
over_tenant_exposure: milliseconds until the exposure window rolls over.maxStakenumberoptionalOn
over_wager_limitandstake_exceeds_stale_limit: the largest stake, in major units, that would be accepted.maxCentsnumberoptionalOn
line_not_available: the executable price, in cents, that put the line outside the wagerable band. A price, not an amount of money.requestedStakenumberoptionalOn
stake_exceeds_available_depth: the stake you asked for.supportedStakenumberoptionalOn
stake_exceeds_available_depth: the largest stake the book can fill at these terms. Re-quote at it to accept.orderIdstringoptionalOn
quote_already_usedandidempotency_conflictfromPOST /api/v1/orders: seeOrderConflict.executionRefstringoptionalOn a
POST /api/v1/ordersrefusal that closed an order Parity had already recorded (rejected,reconciliation_required,insufficient_collateral,insufficient_position): that order’s Parity execution reference. Quote it to Parity support.detailnever quotes a venue order id; this reference stands in for one.sellableContractsnumberoptionalOn
insufficient_positionandbelow_venue_minimumfrom a live cash out quote: the most contracts this customer could sell now, on the hundredth-of-a-contract grid.minimumContractsnumberoptionalOn the same two refusals: the smallest sale, in contracts, this market accepts.
- 403application/json · Error
The key is real and may not do this.
insufficient_scopenames the scope to add;operator_suspendedmeans the operator is not active (any status other than active);operator_archivedmeans Parity archived the operator, and every request with its keys is refused;operator_not_permittedmeansx-parity-operatornames an operator this key may not act for;mode_mismatchmeansx-parity-operatornames an operator in the other mode than the key (a sandbox key for a live operator, or a live key for a sandbox one), which is never allowed;sandbox_onlymeans the endpoint models a Parity-held balance and exists for sandbox integration only.Codes:
insufficient_scope,operator_suspended,operator_archived,operator_not_permitted,mode_mismatch,sandbox_only.Show response fieldsHide response fields
errorstringrequiredMachine-readable code.
messagestringoptionaldetailanyoptionalPresent on validation failures and some refusals.
requiredstring | arrayoptionalOn
insufficient_scope: the scope this key needs. A single scope from the key gate; an array of every scope the call needs fromPOST /embed-sessionsandDELETE /embed-sessions/{id}.acceptedScopesstring[]optionalOn
insufficient_scopefrom a route that accepts any one of several scopes (the player limit, status, statement and audit routes): every scope that would pass.requiredis still the first of them.missingstring[]optionalOn
insufficient_scopefromPOST /embed-sessionsorDELETE /embed-sessions/{id}: the required scopes this key does not carry.supportedanyoptionalThe values that would have been accepted. On
invalid_typefromGET /reconciliation/feedand from both player activity feeds: the known item types, as an array of strings. Onstake_exceeds_available_depththe figure issupportedStakeinstead.statestring · nullableoptionalOn the refusals of
POST /orders/{id}/cancelandPOST /orders/{id}/confirm-reserve: the order's execution state when it was refused, or null for an unknown order.transmissionStatestring · enumoptionalOn the refusals of
POST /orders/{id}/cancel.unknownmeans keep holding the authorization;resolvedmeans the order's ownoperatorMoneyalready says what to apply.Possible values:
not_transmittedunknownresolvedearlieststringoptionalOn
updated_since_too_oldfrom the player activity feeds: the earliest instant the feed can answer from.format: date-time
noOrderForKeybooleanoptionalOn
quote_not_found,quote_expiredanduser_suspendedfromPOST /api/v1/orders: proof that no earlier request under thisclientOrderIdplaced an order.queuedbooleanoptionalOn
503 order_in_progress: this request was never run, because Parity was too busy to start it. Resend it unchanged.retryAfterSecondsnumberoptionalOn every
rate_limited: seconds until the window resets.Retry-Aftercarries the same figure.retryAfterMsnumberoptionalOn
over_tenant_exposure: milliseconds until the exposure window rolls over.maxStakenumberoptionalOn
over_wager_limitandstake_exceeds_stale_limit: the largest stake, in major units, that would be accepted.maxCentsnumberoptionalOn
line_not_available: the executable price, in cents, that put the line outside the wagerable band. A price, not an amount of money.requestedStakenumberoptionalOn
stake_exceeds_available_depth: the stake you asked for.supportedStakenumberoptionalOn
stake_exceeds_available_depth: the largest stake the book can fill at these terms. Re-quote at it to accept.orderIdstringoptionalOn
quote_already_usedandidempotency_conflictfromPOST /api/v1/orders: seeOrderConflict.executionRefstringoptionalOn a
POST /api/v1/ordersrefusal that closed an order Parity had already recorded (rejected,reconciliation_required,insufficient_collateral,insufficient_position): that order’s Parity execution reference. Quote it to Parity support.detailnever quotes a venue order id; this reference stands in for one.sellableContractsnumberoptionalOn
insufficient_positionandbelow_venue_minimumfrom a live cash out quote: the most contracts this customer could sell now, on the hundredth-of-a-contract grid.minimumContractsnumberoptionalOn the same two refusals: the smallest sale, in contracts, this market accepts.
- 429application/json · Error
Over the per-key limit, or over the ceiling shared by every key the operator holds (
messagesays which).Retry-AfterandretryAfterSecondscarry the wait; theRateLimit-*headers always describe the key.Codes:
rate_limited.Show response fieldsHide response fields
errorstringrequiredMachine-readable code.
messagestringoptionaldetailanyoptionalPresent on validation failures and some refusals.
requiredstring | arrayoptionalOn
insufficient_scope: the scope this key needs. A single scope from the key gate; an array of every scope the call needs fromPOST /embed-sessionsandDELETE /embed-sessions/{id}.acceptedScopesstring[]optionalOn
insufficient_scopefrom a route that accepts any one of several scopes (the player limit, status, statement and audit routes): every scope that would pass.requiredis still the first of them.missingstring[]optionalOn
insufficient_scopefromPOST /embed-sessionsorDELETE /embed-sessions/{id}: the required scopes this key does not carry.supportedanyoptionalThe values that would have been accepted. On
invalid_typefromGET /reconciliation/feedand from both player activity feeds: the known item types, as an array of strings. Onstake_exceeds_available_depththe figure issupportedStakeinstead.statestring · nullableoptionalOn the refusals of
POST /orders/{id}/cancelandPOST /orders/{id}/confirm-reserve: the order's execution state when it was refused, or null for an unknown order.transmissionStatestring · enumoptionalOn the refusals of
POST /orders/{id}/cancel.unknownmeans keep holding the authorization;resolvedmeans the order's ownoperatorMoneyalready says what to apply.Possible values:
not_transmittedunknownresolvedearlieststringoptionalOn
updated_since_too_oldfrom the player activity feeds: the earliest instant the feed can answer from.format: date-time
noOrderForKeybooleanoptionalOn
quote_not_found,quote_expiredanduser_suspendedfromPOST /api/v1/orders: proof that no earlier request under thisclientOrderIdplaced an order.queuedbooleanoptionalOn
503 order_in_progress: this request was never run, because Parity was too busy to start it. Resend it unchanged.retryAfterSecondsnumberoptionalOn every
rate_limited: seconds until the window resets.Retry-Aftercarries the same figure.retryAfterMsnumberoptionalOn
over_tenant_exposure: milliseconds until the exposure window rolls over.maxStakenumberoptionalOn
over_wager_limitandstake_exceeds_stale_limit: the largest stake, in major units, that would be accepted.maxCentsnumberoptionalOn
line_not_available: the executable price, in cents, that put the line outside the wagerable band. A price, not an amount of money.requestedStakenumberoptionalOn
stake_exceeds_available_depth: the stake you asked for.supportedStakenumberoptionalOn
stake_exceeds_available_depth: the largest stake the book can fill at these terms. Re-quote at it to accept.orderIdstringoptionalOn
quote_already_usedandidempotency_conflictfromPOST /api/v1/orders: seeOrderConflict.executionRefstringoptionalOn a
POST /api/v1/ordersrefusal that closed an order Parity had already recorded (rejected,reconciliation_required,insufficient_collateral,insufficient_position): that order’s Parity execution reference. Quote it to Parity support.detailnever quotes a venue order id; this reference stands in for one.sellableContractsnumberoptionalOn
insufficient_positionandbelow_venue_minimumfrom a live cash out quote: the most contracts this customer could sell now, on the hundredth-of-a-contract grid.minimumContractsnumberoptionalOn the same two refusals: the smallest sale, in contracts, this market accepts.
- 500application/json · Error
Unexpected server failure. Safe to retry a read.
Codes:
internal_error.Show response fieldsHide response fields
errorstringrequiredMachine-readable code.
messagestringoptionaldetailanyoptionalPresent on validation failures and some refusals.
requiredstring | arrayoptionalOn
insufficient_scope: the scope this key needs. A single scope from the key gate; an array of every scope the call needs fromPOST /embed-sessionsandDELETE /embed-sessions/{id}.acceptedScopesstring[]optionalOn
insufficient_scopefrom a route that accepts any one of several scopes (the player limit, status, statement and audit routes): every scope that would pass.requiredis still the first of them.missingstring[]optionalOn
insufficient_scopefromPOST /embed-sessionsorDELETE /embed-sessions/{id}: the required scopes this key does not carry.supportedanyoptionalThe values that would have been accepted. On
invalid_typefromGET /reconciliation/feedand from both player activity feeds: the known item types, as an array of strings. Onstake_exceeds_available_depththe figure issupportedStakeinstead.statestring · nullableoptionalOn the refusals of
POST /orders/{id}/cancelandPOST /orders/{id}/confirm-reserve: the order's execution state when it was refused, or null for an unknown order.transmissionStatestring · enumoptionalOn the refusals of
POST /orders/{id}/cancel.unknownmeans keep holding the authorization;resolvedmeans the order's ownoperatorMoneyalready says what to apply.Possible values:
not_transmittedunknownresolvedearlieststringoptionalOn
updated_since_too_oldfrom the player activity feeds: the earliest instant the feed can answer from.format: date-time
noOrderForKeybooleanoptionalOn
quote_not_found,quote_expiredanduser_suspendedfromPOST /api/v1/orders: proof that no earlier request under thisclientOrderIdplaced an order.queuedbooleanoptionalOn
503 order_in_progress: this request was never run, because Parity was too busy to start it. Resend it unchanged.retryAfterSecondsnumberoptionalOn every
rate_limited: seconds until the window resets.Retry-Aftercarries the same figure.retryAfterMsnumberoptionalOn
over_tenant_exposure: milliseconds until the exposure window rolls over.maxStakenumberoptionalOn
over_wager_limitandstake_exceeds_stale_limit: the largest stake, in major units, that would be accepted.maxCentsnumberoptionalOn
line_not_available: the executable price, in cents, that put the line outside the wagerable band. A price, not an amount of money.requestedStakenumberoptionalOn
stake_exceeds_available_depth: the stake you asked for.supportedStakenumberoptionalOn
stake_exceeds_available_depth: the largest stake the book can fill at these terms. Re-quote at it to accept.orderIdstringoptionalOn
quote_already_usedandidempotency_conflictfromPOST /api/v1/orders: seeOrderConflict.executionRefstringoptionalOn a
POST /api/v1/ordersrefusal that closed an order Parity had already recorded (rejected,reconciliation_required,insufficient_collateral,insufficient_position): that order’s Parity execution reference. Quote it to Parity support.detailnever quotes a venue order id; this reference stands in for one.sellableContractsnumberoptionalOn
insufficient_positionandbelow_venue_minimumfrom a live cash out quote: the most contracts this customer could sell now, on the hundredth-of-a-contract grid.minimumContractsnumberoptionalOn the same two refusals: the smallest sale, in contracts, this market accepts.