SEP-24SEP-31SEP-6
Create Custody Transaction
POSThttps://custody-server.exampleanchor.com/transactions
Custody Server creates custody transaction record in DB.
Request
- application/json
Body
idstring
SEP transaction ID.
memostring
Memo value, that is used to identify inbound or outbound payments.
memoTypestring
Type of memo, that is used to identify inbound or outbound payments.
Possible values: [id
, hash
, text
]
protocolstring
Protocol of SEP transaction.
Possible values: [6
, 24
, 31
]
fromAccountstring
Source Stellar account.
toAccountstring
Destination Stellar account.
amountstring
Amount of the asset, that is sent/received.
amountFeestring
Fee of SEP transaction.
assetstring
Asset, that is sent/received.
kindstring
Kind of the SEP transaction.
Possible values: [deposit
, withdrawal
, receive
]
Responses
- 200
- 500
Success.
- application/json
- Schema
- Example (from schema)
Schema
object
{}
Internal Server Error
- application/json
- Schema
- Example (from schema)
Schema
errorstringrequired
{
"error": "string"
}
- csharp
- curl
- dart
- go
- http
- java
- javascript
- kotlin
- c
- nodejs
- objective-c
- ocaml
- php
- powershell
- python
- r
- ruby
- rust
- shell
- swift
- HTTPCLIENT
- RESTSHARP
var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Post, "https://custody-server.exampleanchor.com/transactions");
request.Headers.Add("Accept", "application/json");
var content = new StringContent("{\n \"id\": \"string\",\n \"memo\": \"string\",\n \"memoType\": \"id\",\n \"protocol\": \"6\",\n \"fromAccount\": \"string\",\n \"toAccount\": \"string\",\n \"amount\": \"string\",\n \"amountFee\": \"string\",\n \"asset\": \"string\",\n \"kind\": \"deposit\"\n}", null, "application/json");
request.Content = content;
var response = await client.SendAsync(request);
response.EnsureSuccessStatusCode();
Console.WriteLine(await response.Content.ReadAsStringAsync());
Did you find this page helpful?