Skip to content

Commit

Permalink
[ANCHOR-251] OpenAPI SEP-31 updates (#125)
Browse files Browse the repository at this point in the history
* OpenAPI SEP-31 updates

* English...

* Address comments
  • Loading branch information
Ifropc authored Apr 24, 2023
1 parent e1047cb commit 617d899
Show file tree
Hide file tree
Showing 18 changed files with 67 additions and 203 deletions.
7 changes: 5 additions & 2 deletions ap_api/callbacks/customer/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,19 @@ order: 0

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

The Anchor Platform does not store customer KYC data. Instead, the Anchor Platform forwards this data to and requests it from the business.

The customer callbacks are designed for this purpose. Currently, requests & responses for these endpoints are almost identical to the [SEP-12 KYC API specification][sep-12].

<EndpointsTable title="Endpoints">

| | |
| --- | --------------------- |
| GET | [/customer](../get-customer.api.mdx) |
| PUT | [/customer](../put-customer.api.mdx) |
| PUT | [/customer/callback](../put-customer-callback.api.mdx) |
| DELETE | [/customer/:id](../del-customer.api.mdx) |


</EndpointsTable>

[sep-38]: https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0038.md
[sep-12]: https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0012.md
8 changes: 5 additions & 3 deletions ap_api/callbacks/del-customer.api.mdx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
---
id: del-customer
title: "Delete Customer Data"
description: "The request for this endpoint is identical to the `PUT /customer/callback` request defined in SEP-12."
description: "The request for this endpoint is identical to the"
sidebar_label: "Delete Customer Data"
hide_title: true
hide_table_of_contents: true
api: {"tags":["Customers"],"description":"The request for this endpoint is identical to the `PUT /customer/callback` request defined in SEP-12.\n\nDelete the customer's data or queue the customers data for deletion.\n","operationId":"delCustomer","parameters":[{"in":"path","name":"id","schema":{"type":"string"},"required":true}],"responses":{"204":{"description":"Success."},"404":{"description":"Customer not found.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"id":{"type":"string"}},"required":["error"],"title":"Error"}}}}},"method":"delete","path":"/customer/{id}","info":{"version":"2.0.0","description":"The Synchronous Callbacks API specification for the Stellar Anchor Platform project.\n\nThe Synchronous Callbacks API defines requests made by the Platform while it is processing a request from a client application. The \nanchor's responses to these requests affect the Platform responses to the client application.\n","title":"Synchronous Callbacks API"},"postman":{"name":"Delete Customer Data","description":{"content":"The request for this endpoint is identical to the `PUT /customer/callback` request defined in SEP-12.\n\nDelete the customer's data or queue the customers data for deletion.\n","type":"text/plain"},"url":{"path":["customer",":id"],"host":["{{baseUrl}}"],"query":[],"variable":[{"disabled":false,"description":{"content":"(Required) ","type":"text/plain"},"type":"any","value":"","key":"id"}]},"header":[{"key":"Accept","value":"application/json"}],"method":"DELETE"}}
api: {"tags":["Customers"],"description":"The request for this endpoint is identical to the \n[`DELETE /customer`](https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0012.md#customer-delete) \nrequest defined in SEP-12.\n\nDelete the customer's data or queue the customers data for deletion.\n","operationId":"delCustomer","parameters":[{"in":"path","name":"id","schema":{"type":"string"},"required":true}],"responses":{"204":{"description":"Success."},"404":{"description":"Customer not found.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"id":{"type":"string"}},"required":["error"],"title":"Error"}}}}},"method":"delete","path":"/customer/{id}","info":{"version":"2.0.0","description":"The Synchronous Callbacks API specification for the Stellar Anchor Platform project.\n\nThe Synchronous Callbacks API defines requests made by the Platform while it is processing a request from a client application. The \nanchor's responses to these requests affect the Platform responses to the client application.\n","title":"Synchronous Callbacks API"},"postman":{"name":"Delete Customer Data","description":{"content":"The request for this endpoint is identical to the \n[`DELETE /customer`](https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0012.md#customer-delete) \nrequest defined in SEP-12.\n\nDelete the customer's data or queue the customers data for deletion.\n","type":"text/plain"},"url":{"path":["customer",":id"],"host":["{{baseUrl}}"],"query":[],"variable":[{"disabled":false,"description":{"content":"(Required) ","type":"text/plain"},"type":"any","value":"","key":"id"}]},"header":[{"key":"Accept","value":"application/json"}],"method":"DELETE"}}
sidebar_class_name: "delete api-method"
info_path: api/callbacks/synchronous-callbacks-api
custom_edit_url: null
Expand All @@ -24,7 +24,9 @@ import TabItem from "@theme/TabItem";



The request for this endpoint is identical to the `PUT /customer/callback` request defined in SEP-12.
The request for this endpoint is identical to the
[`DELETE /customer`](https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0012.md#customer-delete)
request defined in SEP-12.

Delete the customer's data or queue the customers data for deletion.

Expand Down
6 changes: 4 additions & 2 deletions ap_api/callbacks/fee/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ order: 0

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

The `/fee` is a special endpoint, that is called to fetch fee information for a transaction without a quote.

For example, if your business supports clients who want to skip the quote creation process and will be using the businesses' market rate.

<EndpointsTable title="Endpoints">

| | |
Expand All @@ -13,5 +17,3 @@ import {EndpointsTable} from "@site/src/components/EndpointsTable";


</EndpointsTable>

[sep-38]: https://github.com/stellar/stellar-protocol/blob/master/ecosystem/sep-0038.md
Loading

0 comments on commit 617d899

Please sign in to comment.