Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add transaction_id to customer callback endpoints #672

Merged
merged 3 commits into from
Jun 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions openapi/anchor-platform/Callbacks API.yml
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,7 @@ paths:
If the server still needs more info, or the server needs updated information, it should return the fields required.
tags:
- Customers
- SEP-6
- SEP-12
- SEP-31
summary: Retrieve Customer's Info
Expand Down Expand Up @@ -365,6 +366,13 @@ paths:
documented in SEP-12.
schema:
type: string
- in: query
name: transaction_id
description: |
The transaction id with which the customer's info is associated. When information from the customer depends on the
transaction (e.g., more information is required for larger amounts)
schema:
type: string
- in: query
name: lang
description: |
Expand Down Expand Up @@ -400,6 +408,7 @@ paths:
put:
tags:
- Customers
- SEP-6
- SEP-12
- SEP-24
- SEP-31
Expand Down
14 changes: 14 additions & 0 deletions openapi/anchor-platform/bundled_callback.yml
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,7 @@ paths:
If the server still needs more info, or the server needs updated information, it should return the fields required.
tags:
- Customers
- SEP-6
- SEP-12
- SEP-31
summary: Retrieve Customer's Info
Expand Down Expand Up @@ -364,6 +365,13 @@ paths:
documented in SEP-12.
schema:
type: string
- in: query
name: transaction_id
description: |
The transaction id with which the customer's info is associated. When information from the customer depends on the
transaction (e.g., more information is required for larger amounts)
schema:
type: string
- in: query
name: lang
description: |
Expand Down Expand Up @@ -399,6 +407,7 @@ paths:
put:
tags:
- Customers
- SEP-6
- SEP-12
- SEP-24
- SEP-31
Expand Down Expand Up @@ -668,6 +677,11 @@ components:
For SEP-31 you can define your own types in the assets configuration.
For SEP-24 pre-defined value `sep24-customer` is used.
type: string
transaction_id:
description: |
The transaction id with which the customer's info is associated. When information from the customer depends on the
transaction (e.g., more information is required for larger amounts)
type: string
first_name:
type: string
last_name:
Expand Down
5 changes: 5 additions & 0 deletions openapi/anchor-platform/schemas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@ components:
For SEP-31 you can define your own types in the assets configuration.
For SEP-24 pre-defined value `sep24-customer` is used.
type: string
transaction_id:
description: |
The transaction id with which the customer's info is associated. When information from the customer depends on the
transaction (e.g., more information is required for larger amounts)
type: string
first_name:
type: string
last_name:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ description: "The request and response for this endpoint is identical to the"
sidebar_label: "Retrieve Customer's Info"
hide_title: true
hide_table_of_contents: true
api: eJztWG1v3LgR/isD9kMaQPtix3e97DdjvUm3d3Vcr3PAwTZsrjha8SKROg5lZ2Hsfy+GlPbFVuxLnCt6bfzFWokcPvP2zHDuhEJKna68tkaMxFmO4PC3GsmDNAocUmUNIWTWgc81ARpVWW08aAKt0HidygK8BZ/jhTm/fjs5g0Fak7cluuvLv+beVzQaDBba5/W8n9pyQB6LQrr2f69y1tvUFoN5YeeDUpJHN8DU0pI8lgPCqjcc7u33S/WXVnBvgf7lhemEqjDTBhVoA7PJSW9vv39hLszZDnhZFPaWIC00Gk/g7YjXAOz14Q36NGdtINNYKAqPhO4GXTCNdkgs2zqFjhV3uNAMGSQYvIUWItxoCbKBwJY5ef8fsUxV+5etD1mpabatgbJIYKyHXN4gyA3aVgtUja8RKulkiR4dASF73ITXjewEtAfKbV2w7X3tTAyBxmqNqdRmV3RPHzjGSJabV62UOTaCUMFtjgaM3cYgHQYc/eiq/T6Mc0w/RO289DWBzbZV8rn0UMolyMKhVMt4QKvmOigexAKkQe5tjj7HaIpWJns+s66UnC9wKwlkmmLlUSXg8FdMw5N1QF4XBRhERVBah2Ff/743OleF/VuL4ue6UtIHc67P7/YA3HNA/8KIRHi5IDE6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Xk8b32da50jV2xF3+v4FJf/57b4nNBiEdsEF4vYOqYi9sv4dPJ2MjqcTd4fX56O//VhclrHGhqjTReuVcRq4utG7aTL6dW7TavZcAPBxk+8KPNgimmVJGjtT7+OfAJWRUH2DQUs4RbD3aHVcmScCjsqsGFnWuX5kor8C+E5jJcUH0gl0dNWk5lM7CW4nx782HuVpnu9gzffi96b/YNB7wf+/UD8OHidpH5TY9O26ToiLpXGustQgHbJerZdXv1S8EujO466e9wqYjn/s7Jp5WeJxoLL/JILYdDaR8X71dCs/lNH1H8RO+iqY2MKqfhLmHg7ce8L0aibjVfb1BB2X2wC1sNjDf6Du/iPtYO3ulLia9DBp6nLdH3r87c9l7EhWw8uiHxUqumUazQ26LgfD+JB981qqZLMaEU3uBHP8zlPPlo4PJnAVqe7njk0N7FDlWTabC5apdFkiXqU85Dc0CbYpvOxUHCBTROzlneTyRzp/iwtySZaCBesZqTkm1deTwWg5Sw/wDhX3AN8Ydcdja3bFYubo3maYuK2T95d33VEuLLX3rlXVfJ3qa0ruA+eurU9RWckXuO643thYUIeu1Nv1sH4bez3bez3bez3Pzn2C4WApiX9MufS94CV8c1hYPYztmb2i4hl2jp6d3s75xY/mHy1otfh9kzTPiEt3XAFG6Y8t/gIpzznwK9TlY+4bMaNdevGGN35Pw/mM43/HkC4GT5+Acy/fij4gAb1qPIL4H/5iPAReM108hkwfv3jwQds9Qxm+krnhA8ZZXc6+kTz/JcNER/QuJ6BbvS8oH+MpMPZ8Iyu8xlygcYTf9hz6Mtea9edWwxJWV8h3o1nbLX6A2ULsGs=
sidebar_class_name: "get api-method"
info_path: platforms/anchor-platform/api-reference/callbacks/synchronous-callbacks-api
custom_edit_url: null
---

import { SepBadge } from "@site/src/components/SepBadge";

<SepBadge tags={"Customers,SEP-12,SEP-31"}/>
<SepBadge tags={"Customers,SEP-6,SEP-12,SEP-31"}/>

import ApiTabs from "@theme/ApiTabs";
import DiscriminatorTabs from "@theme/DiscriminatorTabs";
Expand Down Expand Up @@ -54,7 +54,7 @@ If the server still needs more info, or the server needs updated information, it

## Request

<details style={{"marginBottom":"1rem"}} className={"openapi-markdown__details"} data-collapsed={false} open={true}><summary style={{}}><h3 className={"openapi-markdown__details-summary-header-params"}>Query Parameters</h3></summary><div><ul><ParamsItem className={"paramsItem"} param={{"in":"query","name":"id","description":"The ID of the customer as returned in the response of a previous PUT request.","schema":{"type":"string"}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"account","description":"The Stellar or Muxed Account authenticated with the Platform via SEP-10.","schema":{"type":"string"}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"memo","description":"The memo value identifying a customer with a shared account, where the shared account is `account`.","schema":{"type":"string"}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"memo_type","description":"The type of memo used to identify a customer with a shared account.","schema":{"type":"string","enum":["id","hash","text"]}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"type","description":"The type of action the customer is being KYCd for. See the\n[Type Specification](https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0012.md#type-specification)\ndocumented in SEP-12.\n","schema":{"type":"string"}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"lang","description":"Defaults to `en`. Language code specified using ISO 639-1. Human readable descriptions, choices, and\nmessages should be in this language.\n","schema":{"type":"string"}}}></ParamsItem></ul></div></details><div><div><ApiTabs label={undefined} id={undefined}><TabItem label={"200"} value={"200"}><div>
<details style={{"marginBottom":"1rem"}} className={"openapi-markdown__details"} data-collapsed={false} open={true}><summary style={{}}><h3 className={"openapi-markdown__details-summary-header-params"}>Query Parameters</h3></summary><div><ul><ParamsItem className={"paramsItem"} param={{"in":"query","name":"id","description":"The ID of the customer as returned in the response of a previous PUT request.","schema":{"type":"string"}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"account","description":"The Stellar or Muxed Account authenticated with the Platform via SEP-10.","schema":{"type":"string"}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"memo","description":"The memo value identifying a customer with a shared account, where the shared account is `account`.","schema":{"type":"string"}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"memo_type","description":"The type of memo used to identify a customer with a shared account.","schema":{"type":"string","enum":["id","hash","text"]}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"type","description":"The type of action the customer is being KYCd for. See the\n[Type Specification](https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0012.md#type-specification)\ndocumented in SEP-12.\n","schema":{"type":"string"}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"transaction_id","description":"The transaction id with which the customer's info is associated. When information from the customer depends on the\ntransaction (e.g., more information is required for larger amounts)\n","schema":{"type":"string"}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"lang","description":"Defaults to `en`. Language code specified using ISO 639-1. Human readable descriptions, choices, and\nmessages should be in this language.\n","schema":{"type":"string"}}}></ParamsItem></ul></div></details><div><div><ApiTabs label={undefined} id={undefined}><TabItem label={"200"} value={"200"}><div>

Valid request. Customer either already exists or the customer identified by the parameters is new and must
provide the field values described in the response body. Response bodies are identical to the schema defined
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ Success.

An object describing the fees added on top of the rate provided via the `price` attribute.

</div><SchemaItem collapsible={false} name={"total"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","description":"The total fee to be applied."}}></SchemaItem><SchemaItem collapsible={false} name={"asset"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","description":"The asset the fee will be charged in. Must be represented in [Asset Identification Format](https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0038.md#asset-identification-format)."}}></SchemaItem><SchemaItem collapsible={true} className={"schemaItem"}><details style={{}} className={"openapi-markdown__details"}><summary style={{}}><span className={"openapi-schema__container"}><strong className={"openapi-schema__property"}>details</strong><span className={"openapi-schema__name"}> object[]</span></span></summary><div style={{"marginLeft":"1rem"}}><li><div style={{"fontSize":"var(--ifm-code-font-size)","opacity":"0.6","marginLeft":"-.5rem","paddingBottom":".5rem"}}>Array [</div></li><SchemaItem collapsible={false} name={"name"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","description":"The name of the fee, for example `ACH fee`, `Brazilian conciliation fee`, `Service fee`, etc."}}></SchemaItem><SchemaItem collapsible={false} name={"description"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","description":"A text describing the fee."}}></SchemaItem><SchemaItem collapsible={false} name={"amount"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","description":"The amount of asset applied. If `fee.details` is provided, `sum(fee.details.amount)` should be equals `fee.total`."}}></SchemaItem><li><div style={{"fontSize":"var(--ifm-code-font-size)","opacity":"0.6","marginLeft":"-.5rem"}}>]</div></li></div></details></SchemaItem></div></details></SchemaItem></div></details></SchemaItem></ul></details></TabItem><TabItem label={"Example (from schema)"} value={"Example (from schema)"}><ResponseSamples responseExample={"{\n \"rate\": {\n \"id\": \"string\",\n \"expires_at\": \"2024-06-17T20:30:01.206Z\",\n \"price\": \"string\",\n \"sell_amount\": \"string\",\n \"buy_amount\": \"string\",\n \"fee\": {\n \"total\": \"string\",\n \"asset\": \"string\",\n \"details\": [\n {\n \"name\": \"string\",\n \"description\": \"string\",\n \"amount\": \"string\"\n }\n ]\n }\n }\n}"} language={"json"}></ResponseSamples></TabItem></SchemaTabs></TabItem></MimeTabs></div></TabItem><TabItem label={"422"} value={"422"}><div>
</div><SchemaItem collapsible={false} name={"total"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","description":"The total fee to be applied."}}></SchemaItem><SchemaItem collapsible={false} name={"asset"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","description":"The asset the fee will be charged in. Must be represented in [Asset Identification Format](https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0038.md#asset-identification-format)."}}></SchemaItem><SchemaItem collapsible={true} className={"schemaItem"}><details style={{}} className={"openapi-markdown__details"}><summary style={{}}><span className={"openapi-schema__container"}><strong className={"openapi-schema__property"}>details</strong><span className={"openapi-schema__name"}> object[]</span></span></summary><div style={{"marginLeft":"1rem"}}><li><div style={{"fontSize":"var(--ifm-code-font-size)","opacity":"0.6","marginLeft":"-.5rem","paddingBottom":".5rem"}}>Array [</div></li><SchemaItem collapsible={false} name={"name"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","description":"The name of the fee, for example `ACH fee`, `Brazilian conciliation fee`, `Service fee`, etc."}}></SchemaItem><SchemaItem collapsible={false} name={"description"} required={false} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","description":"A text describing the fee."}}></SchemaItem><SchemaItem collapsible={false} name={"amount"} required={true} schemaName={"string"} qualifierMessage={undefined} schema={{"type":"string","description":"The amount of asset applied. If `fee.details` is provided, `sum(fee.details.amount)` should be equals `fee.total`."}}></SchemaItem><li><div style={{"fontSize":"var(--ifm-code-font-size)","opacity":"0.6","marginLeft":"-.5rem"}}>]</div></li></div></details></SchemaItem></div></details></SchemaItem></div></details></SchemaItem></ul></details></TabItem><TabItem label={"Example (from schema)"} value={"Example (from schema)"}><ResponseSamples responseExample={"{\n \"rate\": {\n \"id\": \"string\",\n \"expires_at\": \"2024-06-20T20:14:48.798Z\",\n \"price\": \"string\",\n \"sell_amount\": \"string\",\n \"buy_amount\": \"string\",\n \"fee\": {\n \"total\": \"string\",\n \"asset\": \"string\",\n \"details\": [\n {\n \"name\": \"string\",\n \"description\": \"string\",\n \"amount\": \"string\"\n }\n ]\n }\n }\n}"} language={"json"}></ResponseSamples></TabItem></SchemaTabs></TabItem></MimeTabs></div></TabItem><TabItem label={"422"} value={"422"}><div>

Unprocessable Entity. This status should be returned when the anchor understood the request but cannot
return a success response.
Expand Down
Loading
Loading