Skip to content

LSv2 Participant Ledger v2.1

Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

API provided by the LSv2 Participant Ledger

Base URLs:

Authentication

  • HTTP Authentication, scheme: basic Pass username and password in the Authorization header using BASIC authentication.

  • HTTP Authentication, scheme: bearer Use a token returned from one of the auth endpoints.

auth

Authentication

auth_basic

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/auth',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/auth', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/auth");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/auth", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/auth \
  -H 'Accept: application/json'

GET /api/v2/auth

Authenticate to the system as an administrator or user. The user should provide BASIC authentication details.

Example responses

200 Response

{
  "flags": [
    {
      "name": "string",
      "value": true
    }
  ],
  "token": "string"
}

Responses

Status Meaning Description Schema
200 OK Token AuthResponse

auth_login

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "password": "cheese000!!",
  "userName": "user123"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'
};

fetch('https://{instance}/api/v2/auth',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://{instance}/api/v2/auth', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/auth");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
        "Authorization": []string{"Bearer {access-token}"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://{instance}/api/v2/auth", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X POST https://{instance}/api/v2/auth \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST /api/v2/auth

Authenticate to the system as an administrator or user

Body parameter

{
  "password": "cheese000!!",
  "userName": "user123"
}

Parameters

Name In Type Required Description
body body AuthRequest false The authentication request

Example responses

200 Response

{
  "flags": [
    {
      "name": "string",
      "value": true
    }
  ],
  "token": "string"
}

Responses

Status Meaning Description Schema
200 OK Token AuthResponse

user

User management

user_admin_delete-user

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

fetch('https://{instance}/api/v2/user/{username}',
{
  method: 'DELETE'

})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests

r = requests.delete('https://{instance}/api/v2/user/{username}')

print(r.json())
URL obj = new URL("https://{instance}/api/v2/user/{username}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://{instance}/api/v2/user/{username}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X DELETE https://{instance}/api/v2/user/{username}

DELETE /api/v2/user/{username}

Delete a user. A user cannot delete themselves. Only available to 'admin' users.

Parameters

Name In Type Required Description
username path string true The username

Responses

Status Meaning Description Schema
204 No Content Indicates success None

user_admin_get-user

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/user/{username}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/user/{username}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/user/{username}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/user/{username}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/user/{username} \
  -H 'Accept: application/json'

GET /api/v2/user/{username}

Get a user's details. Only available to 'admin' users.

Parameters

Name In Type Required Description
username path string true The username

Example responses

default Response

{
  "admin": true,
  "userName": "string"
}

Responses

Status Meaning Description Schema
default Default default response UserData

user_admin_create-user

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "isAdmin": true,
  "password": "string"
}';
const headers = {
  'Content-Type':'application/json'
};

fetch('https://{instance}/api/v2/user/{username}',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json'
}

r = requests.post('https://{instance}/api/v2/user/{username}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/user/{username}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://{instance}/api/v2/user/{username}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X POST https://{instance}/api/v2/user/{username} \
  -H 'Content-Type: application/json'

POST /api/v2/user/{username}

Create a new user. Only available to 'admin' users.

Body parameter

{
  "isAdmin": true,
  "password": "string"
}

Parameters

Name In Type Required Description
username path string true The username
body body UserUpdate true none

Responses

Status Meaning Description Schema
201 Created Indicates success None

user_admin_update-user

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "isAdmin": true,
  "password": "string"
}';
const headers = {
  'Content-Type':'application/json'
};

fetch('https://{instance}/api/v2/user/{username}',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json'
}

r = requests.put('https://{instance}/api/v2/user/{username}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/user/{username}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/user/{username}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/user/{username} \
  -H 'Content-Type: application/json'

PUT /api/v2/user/{username}

Update a user, changing the password or their status as an administrator. Only available to 'admin' users.

Body parameter

{
  "isAdmin": true,
  "password": "string"
}

Parameters

Name In Type Required Description
username path string true The username
body body UserUpdate false The updates to the user data

Responses

Status Meaning Description Schema
204 No Content Indicates success None

user_change-password

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "newPassword": "string",
  "oldPassword": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Authorization':'Bearer {access-token}'
};

fetch('https://{instance}/api/v2/user/{username}/password',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.put('https://{instance}/api/v2/user/{username}/password', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/user/{username}/password");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Authorization": []string{"Bearer {access-token}"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/user/{username}/password", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/user/{username}/password \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer {access-token}'

PUT /api/v2/user/{username}/password

Change the current user's password

Body parameter

{
  "newPassword": "string",
  "oldPassword": "string"
}

Parameters

Name In Type Required Description
username path string true The username
body body NewPassword false The old and new passwords

Responses

Status Meaning Description Schema
204 No Content Indicates success None

account

Ledger account management

v3_account_get-all

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v3/account',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v3/account', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v3/account");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v3/account", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v3/account \
  -H 'Accept: application/json'

GET /api/v3/account

Get all account IDs.

Example responses

200 Response

[
  "string"
]

Responses

Status Meaning Description Schema
200 OK List of account IDs Inline

Response Schema

v3_account_get-all-of-type

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v3/account/{accountType}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v3/account/{accountType}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v3/account/{accountType}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v3/account/{accountType}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v3/account/{accountType} \
  -H 'Accept: application/json'

GET /api/v3/account/{accountType}

Get all account IDs of a given type.

Parameters

Name In Type Required Description
accountType path string true The account type

Example responses

200 Response

[
  "string"
]

Responses

Status Meaning Description Schema
200 OK List of account IDs of given type Inline

Response Schema

v3_account_get-all-assets

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v3/account/{accountType}/{accountId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v3/account/{accountType}/{accountId}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v3/account/{accountType}/{accountId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v3/account/{accountType}/{accountId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v3/account/{accountType}/{accountId} \
  -H 'Accept: application/json'

GET /api/v3/account/{accountType}/{accountId}

Get all assets IDs for a given account ID and account type.

Parameters

Name In Type Required Description
accountType path string true The account type
accountId path string true The account ID

Example responses

200 Response

[
  "string"
]

Responses

Status Meaning Description Schema
200 OK List of all asset IDs associated with the account type and ID Inline

Response Schema

v3_account_rename

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "amount": 0,
  "isDelta": true,
  "reason": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json'
};

fetch('https://{instance}/api/v3/account/{accountType}/{accountId}',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

r = requests.post('https://{instance}/api/v3/account/{accountType}/{accountId}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v3/account/{accountType}/{accountId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://{instance}/api/v3/account/{accountType}/{accountId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X POST https://{instance}/api/v3/account/{accountType}/{accountId} \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json'

POST /api/v3/account/{accountType}/{accountId}

Change the ID or type of an account

Body parameter

{
  "amount": 0,
  "isDelta": true,
  "reason": "string"
}

Parameters

Name In Type Required Description
accountType path string true The account Type
accountId path string true The account ID
body body AccountBalanceUpdate false The new account ID and type

Example responses

204 Response

{
  "accountId": "string",
  "accountType": "string",
  "assetId": "string",
  "balances": [
    {
      "amount": 0,
      "label": "string"
    }
  ],
  "external": true,
  "hotBalance": 0,
  "lastProposalAt": "2019-08-24T14:15:22Z",
  "lastSettledAt": "2019-08-24T14:15:22Z",
  "liability": true,
  "settledBalance": 0
}

Responses

Status Meaning Description Schema
204 No Content Updated account and type AccountDTO

v3_account_get

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId} \
  -H 'Accept: application/json'

GET /api/v3/account/{accountType}/{accountId}/{assetId}

Get the account details

Parameters

Name In Type Required Description
accountType path string true The account type
accountId path string true The account ID
assetId path string true The asset ID

Example responses

200 Response

{
  "accountId": "string",
  "accountType": "string",
  "assetId": "string",
  "balances": [
    {
      "amount": 0,
      "label": "string"
    }
  ],
  "external": true,
  "hotBalance": 0,
  "lastProposalAt": "2019-08-24T14:15:22Z",
  "lastSettledAt": "2019-08-24T14:15:22Z",
  "liability": true,
  "settledBalance": 0
}

Responses

Status Meaning Description Schema
200 OK Account details AccountDTO

v3_account_update-settled-balance

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "amount": 0,
  "isDelta": true,
  "reason": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json'
};

fetch('https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

r = requests.post('https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X POST https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId} \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json'

POST /api/v3/account/{accountType}/{accountId}/{assetId}

Update the balance for this account + asset

Body parameter

{
  "amount": 0,
  "isDelta": true,
  "reason": "string"
}

Parameters

Name In Type Required Description
accountType path string true The account Type
accountId path string true The account ID
assetId path string true The asset ID
body body AccountBalanceUpdate false The balance change

Example responses

200 Response

{
  "accountId": "string",
  "accountType": "string",
  "assetId": "string",
  "balances": [
    {
      "amount": 0,
      "label": "string"
    }
  ],
  "external": true,
  "hotBalance": 0,
  "lastProposalAt": "2019-08-24T14:15:22Z",
  "lastSettledAt": "2019-08-24T14:15:22Z",
  "liability": true,
  "settledBalance": 0
}

Responses

Status Meaning Description Schema
200 OK Updated balances for account + asset AccountDTO

v3_account_create

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

fetch('https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}',
{
  method: 'PUT'

})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests

r = requests.put('https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}')

print(r.json())
URL obj = new URL("https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}

PUT /api/v3/account/{accountType}/{accountId}/{assetId}

Create an account with an initial balance of zero.

Parameters

Name In Type Required Description
accountType path string true The account ID
accountId path string true The account ID
assetId path string true The asset ID

Responses

Status Meaning Description Schema
201 Created Account was created None
204 No Content Account already existed None

v3_account_get-pending

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}/pending',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}/pending', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}/pending");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}/pending", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v3/account/{accountType}/{accountId}/{assetId}/pending \
  -H 'Accept: application/json'

GET /api/v3/account/{accountType}/{accountId}/{assetId}/pending

Get pending transfers for this account + asset

Parameters

Name In Type Required Description
accountType path string true The account Type
accountId path string true The account ID
assetId path string true The asset ID

Example responses

200 Response

[
  {
    "accountId": "string",
    "accountType": "string",
    "amount": 0,
    "assetId": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "finalisedAt": "2019-08-24T14:15:22Z",
    "id": 0,
    "isAccepted": true,
    "isFinalised": true,
    "manifestCorrelationId": "string",
    "requestId": "string",
    "swarmId": "string",
    "tags": [
      "string"
    ],
    "transferCorrelationId": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK List of all pending transfers for this account + asset Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [TransferDTO] false none [A credit or debit resulting from a transfer]
» accountId string true none The account ID
» accountType string true none The account type
» amount number true none The amount being transferred. This will be a floating point number.
» assetId string true none The asset ID.
» createdAt string(date-time) true none When the transfer was loaded. This is an ISO-8601 format timestamp
» finalisedAt string(date-time) false none When the manifest was finalised, if it has been.
» id integer(int64) true none The database record ID
» isAccepted boolean false none Only present if the manifest is finalised. Was the manifest accepted?
» isFinalised boolean true none Has the manifest been finalised?
» manifestCorrelationId string true none The correlation ID associated with the manifest that contains the transfer.
» requestId string true none The request ID associated with the manifest that contains the transfer
» swarmId string true none The swarm ID associated with the manifest that contains the transfer
» tags [string] false none Tags assigned to this transfer
» transferCorrelationId string true none The correlation ID associated with the transfer

asset

Asset management

v3_instrument_get-all

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v3/instrument',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v3/instrument', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v3/instrument");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v3/instrument", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v3/instrument \
  -H 'Accept: application/json'

GET /api/v3/instrument

Get all instrument IDs.

Example responses

200 Response

[
  "string"
]

Responses

Status Meaning Description Schema
200 OK List of all instrument IDs Inline

Response Schema

manifest

Manifest approvals and searches

manifest_approve

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/problem+json'
};

fetch('https://{instance}/api/v2/manifest/approve/{swarmId}',
{
  method: 'PUT',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/problem+json'
}

r = requests.put('https://{instance}/api/v2/manifest/approve/{swarmId}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/manifest/approve/{swarmId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/problem+json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/manifest/approve/{swarmId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/manifest/approve/{swarmId} \
  -H 'Accept: application/problem+json'

PUT /api/v2/manifest/approve/{swarmId}

Approve the manifest with the given swarm ID

Parameters

Name In Type Required Description
swarmId path string true The swarm ID of the manifest to approve

Example responses

424 Response

{
  "detail": "string",
  "instance": "string",
  "status": 0,
  "timestamp": "string",
  "title": "string",
  "type": "string"
}

Responses

Status Meaning Description Schema
201 Created The manifest was approved None
424 Failed Dependency The manifest was not found. Note that this may occur if another party has already voted. ErrorResponse

Cancel all open manifests.

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

fetch('https://{instance}/api/v2/manifest/cancel-all',
{
  method: 'DELETE'

})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests

r = requests.delete('https://{instance}/api/v2/manifest/cancel-all')

print(r.json())
URL obj = new URL("https://{instance}/api/v2/manifest/cancel-all");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://{instance}/api/v2/manifest/cancel-all", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X DELETE https://{instance}/api/v2/manifest/cancel-all

DELETE /api/v2/manifest/cancel-all

Every open manifests is immediately marked as rejected in the database and a vote for rejection is sent to the swarm.

Responses

Status Meaning Description Schema
204 No Content All open manifests rejected and closed. None

manifest_reject

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/problem+json'
};

fetch('https://{instance}/api/v2/manifest/reject/{swarmId}',
{
  method: 'PUT',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/problem+json'
}

r = requests.put('https://{instance}/api/v2/manifest/reject/{swarmId}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/manifest/reject/{swarmId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/problem+json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/manifest/reject/{swarmId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/manifest/reject/{swarmId} \
  -H 'Accept: application/problem+json'

PUT /api/v2/manifest/reject/{swarmId}

Reject the manifest with the given swarm ID

Parameters

Name In Type Required Description
swarmId path string true The swarm ID of the manifest to reject

Example responses

424 Response

{
  "detail": "string",
  "instance": "string",
  "status": 0,
  "timestamp": "string",
  "title": "string",
  "type": "string"
}

Responses

Status Meaning Description Schema
201 Created The manifest was rejected None
424 Failed Dependency The manifest was not found. Note this may occur if another party has already voted on the manifest. ErrorResponse

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/manifest/search',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/manifest/search', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/manifest/search");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/manifest/search", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/manifest/search \
  -H 'Accept: application/json'

GET /api/v2/manifest/search

Search for manifests

Parameters

Name In Type Required Description
swarmId query string false The swarm ID to search for
requestId query string false The request ID to search for
correlationId query string false The correlation ID to search for
createdAfter query string false The time after which the manifest was created. This may be provided as a ISO-8601 timestamp indicating an absolute time, or as an ISO-8601 duration indicating a time-before-present.
createdBefore query string false The time before which the manifest was created. This may be provided as a ISO-8601 timestamp indicating an absolute time, or as an ISO-8601 duration indicating a time-before-present.
scope query string false The scope of the search. Defaults to ALL.
offset query integer(int32) false Number of results to skip at start. Defaults to zero.
limit query integer(int32) false Maximum number of results to return. Defaults to ALL.

Enumerated Values

Parameter Value
scope ACTIVE
scope ALL
scope FINALISED

Example responses

200 Response

[
  {
    "correlationId": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "finalised": true,
    "finalisedAt": "2019-08-24T14:15:22Z",
    "isAccepted": true,
    "requestId": "string",
    "swarmId": "string",
    "transfers": [
      {
        "accountId": "string",
        "accountType": "string",
        "amount": 0,
        "assetId": "string",
        "createdAt": "2019-08-24T14:15:22Z",
        "finalisedAt": "2019-08-24T14:15:22Z",
        "id": 0,
        "isAccepted": true,
        "isFinalised": true,
        "manifestCorrelationId": "string",
        "requestId": "string",
        "swarmId": "string",
        "tags": [
          "string"
        ],
        "transferCorrelationId": "string"
      }
    ]
  }
]

Responses

Status Meaning Description Schema
200 OK All matching manifests. Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [ManifestDTO] false none [The manifest of a set of transfers.]
» correlationId string false none Correlation ID assigned by the client, if any.
» createdAt string(date-time) false none When this transaction was loaded into the database.
» finalised boolean false none Is the manifest finalised?
» finalisedAt string(date-time) false none Time at which the manifest was finalised, if it has been.
» isAccepted boolean false none Was the manifest accepted, rejected, or is it still undecided?. This is not present or null if it is undecided.
» requestId string false none Request ID assigned by the scheduler.
» swarmId string false none Swarm ID assigned by the Ledger-Swarm.
» transfers [TransferDTO] false none Transfers associated with this manifest.
»» accountId string true none The account ID
»» accountType string true none The account type
»» amount number true none The amount being transferred. This will be a floating point number.
»» assetId string true none The asset ID.
»» createdAt string(date-time) true none When the transfer was loaded. This is an ISO-8601 format timestamp
»» finalisedAt string(date-time) false none When the manifest was finalised, if it has been.
»» id integer(int64) true none The database record ID
»» isAccepted boolean false none Only present if the manifest is finalised. Was the manifest accepted?
»» isFinalised boolean true none Has the manifest been finalised?
»» manifestCorrelationId string true none The correlation ID associated with the manifest that contains the transfer.
»» requestId string true none The request ID associated with the manifest that contains the transfer
»» swarmId string true none The swarm ID associated with the manifest that contains the transfer
»» tags [string] false none Tags assigned to this transfer
»» transferCorrelationId string true none The correlation ID associated with the transfer

manifest_select

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/manifest/select/{swarmId}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/manifest/select/{swarmId}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/manifest/select/{swarmId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/manifest/select/{swarmId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/manifest/select/{swarmId} \
  -H 'Accept: application/json'

GET /api/v2/manifest/select/{swarmId}

Select the manifest with the given swarm ID

Parameters

Name In Type Required Description
swarmId path string true The swarm ID of the manifest

Example responses

200 Response

{
  "correlationId": "string",
  "createdAt": "2019-08-24T14:15:22Z",
  "finalised": true,
  "finalisedAt": "2019-08-24T14:15:22Z",
  "isAccepted": true,
  "requestId": "string",
  "swarmId": "string",
  "transfers": [
    {
      "accountId": "string",
      "accountType": "string",
      "amount": 0,
      "assetId": "string",
      "createdAt": "2019-08-24T14:15:22Z",
      "finalisedAt": "2019-08-24T14:15:22Z",
      "id": 0,
      "isAccepted": true,
      "isFinalised": true,
      "manifestCorrelationId": "string",
      "requestId": "string",
      "swarmId": "string",
      "tags": [
        "string"
      ],
      "transferCorrelationId": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
200 OK The manifest ManifestDTO
404 Not Found The manifest was not found None

kafka

Search Kafka message history

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/kafka/search',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/kafka/search', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/kafka/search");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/kafka/search", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/kafka/search \
  -H 'Accept: application/json'

GET /api/v2/kafka/search

Search for Kafka messages

Parameters

Name In Type Required Description
swarmId query string false The swarm ID to search for
requestId query string false The request ID to search for
correlationId query string false The correlation ID to search for
createdAfter query string false The time after which the message was created. This may be provided as a ISO-8601 timestamp indicating an absolute time, or as an ISO-8601 duration indicating a time-before-present.
createdBefore query string false The time before which the message was created. This may be provided as a ISO-8601 timestamp indicating an absolute time, or as an ISO-8601 duration indicating a time-before-present.
type query string false The type of the message's envelope
offset query integer(int32) false Number of results to skip at start. Defaults to zero.
limit query integer(int32) false Maximum number of results to return. Defaults to ALL.

Example responses

200 Response

[
  {
    "correlationId": "string",
    "envelopeText": "string",
    "headers": [
      {
        "name": "string",
        "textValue": "string"
      }
    ],
    "receivedAt": "2019-08-24T14:15:22Z",
    "recordKey": "string",
    "requestId": "string",
    "swarmId": "string",
    "type": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK All matching messages. Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [KafkaRecordDTO] false none [A Kafka message with standard LedgerSwarm headers]
» correlationId string false none The correlation ID of the message
» envelopeText string false none Textual representation of the Kafka message, assuming it contained a LedgerSwarm Envelope.
» headers [KafkaHeaderDTO] false none The headers on the message
»» name string false none The name of the header
»» textValue string false none The value of the header as a string
» receivedAt string(date-time) false none The time the message was received
» recordKey string false none The Kafka record key of the message
» requestId string false none The request ID associated with the message.
» swarmId string false none The swarm ID associated with the message.
» type string false none The type of the message.

transfer

Transfer approvals and searches

transfer_get-all

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/transfer',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/transfer', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/transfer");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/transfer", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/transfer \
  -H 'Accept: application/json'

GET /api/v2/transfer

Get all pending transfers.

Example responses

200 Response

{
  "accountId": "string",
  "accountType": "string",
  "amount": 0,
  "assetId": "string",
  "createdAt": "2019-08-24T14:15:22Z",
  "finalisedAt": "2019-08-24T14:15:22Z",
  "id": 0,
  "isAccepted": true,
  "isFinalised": true,
  "manifestCorrelationId": "string",
  "requestId": "string",
  "swarmId": "string",
  "tags": [
    "string"
  ],
  "transferCorrelationId": "string"
}

Responses

Status Meaning Description Schema
200 OK All transfers. TransferDTO

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/transfer/search',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/transfer/search', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/transfer/search");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/transfer/search", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/transfer/search \
  -H 'Accept: application/json'

GET /api/v2/transfer/search

Search for transfers

Parameters

Name In Type Required Description
accountId query string false The account ID to search for
assetId query string false The asset ID to search for
swarmID query string false The swarm ID to search for
requestId query string false The request ID to search for
manifestCorrelationId query string false The manifest correlation ID to search for
transferCorrelationId query string false The transfer correlation ID to search for
scope query string false The scope to search in
offset query integer(int32) false Number of results to skip at start. Defaults to zero.
limit query integer(int32) false Maximum number of results to return. Defaults to ALL.

Enumerated Values

Parameter Value
scope ACTIVE
scope ALL
scope FINALISED

Example responses

200 Response

[
  {
    "accountId": "string",
    "accountType": "string",
    "amount": 0,
    "assetId": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "finalisedAt": "2019-08-24T14:15:22Z",
    "id": 0,
    "isAccepted": true,
    "isFinalised": true,
    "manifestCorrelationId": "string",
    "requestId": "string",
    "swarmId": "string",
    "tags": [
      "string"
    ],
    "transferCorrelationId": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK All matching transfers. Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [TransferDTO] false none [A credit or debit resulting from a transfer]
» accountId string true none The account ID
» accountType string true none The account type
» amount number true none The amount being transferred. This will be a floating point number.
» assetId string true none The asset ID.
» createdAt string(date-time) true none When the transfer was loaded. This is an ISO-8601 format timestamp
» finalisedAt string(date-time) false none When the manifest was finalised, if it has been.
» id integer(int64) true none The database record ID
» isAccepted boolean false none Only present if the manifest is finalised. Was the manifest accepted?
» isFinalised boolean true none Has the manifest been finalised?
» manifestCorrelationId string true none The correlation ID associated with the manifest that contains the transfer.
» requestId string true none The request ID associated with the manifest that contains the transfer
» swarmId string true none The swarm ID associated with the manifest that contains the transfer
» tags [string] false none Tags assigned to this transfer
» transferCorrelationId string true none The correlation ID associated with the transfer

transfer_set-tags

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/transfer/tag/{id}',
{
  method: 'POST',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.post('https://{instance}/api/v2/transfer/tag/{id}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/transfer/tag/{id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://{instance}/api/v2/transfer/tag/{id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X POST https://{instance}/api/v2/transfer/tag/{id} \
  -H 'Accept: application/json'

POST /api/v2/transfer/tag/{id}

Set the tags associated with a transfer.

Parameters

Name In Type Required Description
id path integer(int64) true The transfer ID

Example responses

200 Response

[
  {
    "accountId": "string",
    "accountType": "string",
    "amount": 0,
    "assetId": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "finalisedAt": "2019-08-24T14:15:22Z",
    "id": 0,
    "isAccepted": true,
    "isFinalised": true,
    "manifestCorrelationId": "string",
    "requestId": "string",
    "swarmId": "string",
    "tags": [
      "string"
    ],
    "transferCorrelationId": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK The updated transfer. Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [TransferDTO] false none [A credit or debit resulting from a transfer]
» accountId string true none The account ID
» accountType string true none The account type
» amount number true none The amount being transferred. This will be a floating point number.
» assetId string true none The asset ID.
» createdAt string(date-time) true none When the transfer was loaded. This is an ISO-8601 format timestamp
» finalisedAt string(date-time) false none When the manifest was finalised, if it has been.
» id integer(int64) true none The database record ID
» isAccepted boolean false none Only present if the manifest is finalised. Was the manifest accepted?
» isFinalised boolean true none Has the manifest been finalised?
» manifestCorrelationId string true none The correlation ID associated with the manifest that contains the transfer.
» requestId string true none The request ID associated with the manifest that contains the transfer
» swarmId string true none The swarm ID associated with the manifest that contains the transfer
» tags [string] false none Tags assigned to this transfer
» transferCorrelationId string true none The correlation ID associated with the transfer

rule

Auto-approval rule management

consensus_rule_get-all

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/consensus/rule',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/consensus/rule', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/consensus/rule");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/consensus/rule", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/consensus/rule \
  -H 'Accept: application/json'

GET /api/v2/consensus/rule

Get all rules

Example responses

200 Response

[
  {
    "id": 0,
    "name": "string",
    "priority": 0,
    "text": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK All rules Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [RuleDTO] false none none
» id integer(int64) false none none
» name string true none The rule's name
» priority integer(int32) false none The rule's priority (highest value first)
» text string true none The rule. The rule is a JEXL script that returns one of ACCEPT, REJECT, MANUAL, or ABSTAIN.

consensus_rule_create

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "id": 0,
  "name": "string",
  "priority": 0,
  "text": "string"
}';
const headers = {
  'Content-Type':'application/json'
};

fetch('https://{instance}/api/v2/consensus/rule',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json'
}

r = requests.put('https://{instance}/api/v2/consensus/rule', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/consensus/rule");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/consensus/rule", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/consensus/rule \
  -H 'Content-Type: application/json'

PUT /api/v2/consensus/rule

Add a new rule

Body parameter

{
  "id": 0,
  "name": "string",
  "priority": 0,
  "text": "string"
}

Parameters

Name In Type Required Description
body body RuleDTO false The new rule

Responses

Status Meaning Description Schema
200 OK OK None

consensus_rule_delete

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

fetch('https://{instance}/api/v2/consensus/rule/{id}',
{
  method: 'DELETE'

})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests

r = requests.delete('https://{instance}/api/v2/consensus/rule/{id}')

print(r.json())
URL obj = new URL("https://{instance}/api/v2/consensus/rule/{id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://{instance}/api/v2/consensus/rule/{id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X DELETE https://{instance}/api/v2/consensus/rule/{id}

DELETE /api/v2/consensus/rule/{id}

Delete a rule

Parameters

Name In Type Required Description
id path integer(int64) true The ID of the rule to delete

Responses

Status Meaning Description Schema
200 OK OK None

ping

Ping the server

ping_open

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'
};

fetch('https://{instance}/api/v2/open/ping',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://{instance}/api/v2/open/ping', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/open/ping");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Bearer {access-token}"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/open/ping", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/open/ping \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET /api/v2/open/ping

Ping the server (anonymous)

Example responses

200 Response

{
  "timestamp": "2019-08-24T14:15:22Z",
  "user": "string"
}

Responses

Status Meaning Description Schema
200 OK Ping response PingResponse

properties_open

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'
};

fetch('https://{instance}/api/v2/open/util/participantProperties',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://{instance}/api/v2/open/util/participantProperties', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/open/util/participantProperties");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Bearer {access-token}"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/open/util/participantProperties", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/open/util/participantProperties \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET /api/v2/open/util/participantProperties

Get properties from the server (anonymous)

Example responses

200 Response

{
  "context": "string",
  "instance": "string",
  "domain": "string",
  "id": "string",
  "cluster": "string"
}

Responses

Status Meaning Description Schema
200 OK Participant properties response PropertiesResponse

ping_auth

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/ping',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/ping', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/ping");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/ping", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/ping \
  -H 'Accept: application/json'

GET /api/v2/ping

Ping the server (authenticated)

Example responses

200 Response

{
  "timestamp": "2019-08-24T14:15:22Z",
  "user": "string"
}

Responses

Status Meaning Description Schema
200 OK Ping response PingResponse

propose

Propose new transfers

propose_pacs.008

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = 'string';
const headers = {
  'Content-Type':'application/xml',
  'Accept':'application/xml'
};

fetch('https://{instance}/api/v2/pacs',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/xml',
  'Accept': 'application/xml'
}

r = requests.post('https://{instance}/api/v2/pacs', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/pacs");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/xml"},
        "Accept": []string{"application/xml"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://{instance}/api/v2/pacs", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X POST https://{instance}/api/v2/pacs \
  -H 'Content-Type: application/xml' \
  -H 'Accept: application/xml'

POST /api/v2/pacs

Create a new manifest proposal from a PACS.008 message and inject it into the ledger

Body parameter

Parameters

Name In Type Required Description
body body string false none

Example responses

201 Response

<?xml version="1.0" encoding="UTF-8" ?>
<PacsResponse>
  <error>string</error>
  <manifestId>string</manifestId>
  <status>string</status>
</PacsResponse>

Responses

Status Meaning Description Schema
201 Created Created PacsResponse

propose_create

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "manifestId": "string",
  "transfers": [
    {
      "amount": 0,
      "assetId": "string",
      "from": {
        "account": "string",
        "domain": "string",
        "participant": "string"
      },
      "to": {
        "account": "string",
        "domain": "string",
        "participant": "string"
      },
      "transferId": "string"
    }
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/propose',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

r = requests.put('https://{instance}/api/v2/propose', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/propose");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/propose", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/propose \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json'

PUT /api/v2/propose

Create a new manifest proposal and inject it into the ledger

Body parameter

{
  "manifestId": "string",
  "transfers": [
    {
      "amount": 0,
      "assetId": "string",
      "from": {
        "account": "string",
        "domain": "string",
        "participant": "string"
      },
      "to": {
        "account": "string",
        "domain": "string",
        "participant": "string"
      },
      "transferId": "string"
    }
  ]
}

Parameters

Name In Type Required Description
sc query string false The settlement context
body body Proposal false The proposal

Example responses

201 Response

{
  "manifestId": "string",
  "transferIds": [
    "string"
  ]
}

Responses

Status Meaning Description Schema
201 Created Created ProposalResponse

consensus

Consensus management

delete

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'
};

fetch('https://{instance}/api/v2/consensus?swarmId=string',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.delete('https://{instance}/api/v2/consensus', params={
  'swarmId': 'string'
}, headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/consensus?swarmId=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Bearer {access-token}"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://{instance}/api/v2/consensus", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X DELETE https://{instance}/api/v2/consensus?swarmId=string \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

DELETE /api/v2/consensus

Parameters

Name In Type Required Description
swarmId query string true The Swarm ID of the consensus.

Example responses

Responses

Status Meaning Description Schema
default Default default response None

Response Schema

get

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'
};

fetch('https://{instance}/api/v2/consensus',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://{instance}/api/v2/consensus', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/consensus");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Bearer {access-token}"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/consensus", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/consensus \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET /api/v2/consensus

Parameters

Name In Type Required Description
swarmId query string false The Swarm ID of the consensus.
since query string false The duration, in ISO-8601 format, to search for consensus messages since.

Example responses

default Response

[
  {
    "consensus": "string",
    "finalisedAt": "2019-08-24T14:15:22Z",
    "finalisedStatus": "APPROVED",
    "receivedAt": "2019-08-24T14:15:22Z",
    "swarmId": "string",
    "tags": [
      "string"
    ]
  }
]

Responses

Status Meaning Description Schema
default Default default response Inline

Response Schema

Status Code default

Name Type Required Restrictions Description
anonymous [ConsensusDTO] false none none
» consensus string false none none
» finalisedAt string(date-time) false none none
» finalisedStatus string false none none
» receivedAt string(date-time) false none none
» swarmId string false none none
» tags [string] false none none

Enumerated Values

Property Value
finalisedStatus APPROVED
finalisedStatus REJECTED
finalisedStatus EXPIRED
finalisedStatus UNRECOGNIZED

consensus_create

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = 'string';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/problem+json'
};

fetch('https://{instance}/api/v2/consensus',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/problem+json'
}

r = requests.put('https://{instance}/api/v2/consensus', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/consensus");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/problem+json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/consensus", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/consensus \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/problem+json'

PUT /api/v2/consensus

Create an new consensus proposal.

Body parameter

"string"

Parameters

Name In Type Required Description
sc query string false The settlement context
body body string false The new consensus

Example responses

400 Response

{
  "detail": "string",
  "instance": "string",
  "status": 0,
  "timestamp": "string",
  "title": "string",
  "type": "string"
}

Responses

Status Meaning Description Schema
201 Created Consensus was submitted to the swarm None
400 Bad Request Invalid input ErrorResponse

consensus_approve

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/problem+json'
};

fetch('https://{instance}/api/v2/consensus/approve/{swarmId}',
{
  method: 'PUT',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/problem+json'
}

r = requests.put('https://{instance}/api/v2/consensus/approve/{swarmId}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/consensus/approve/{swarmId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/problem+json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/consensus/approve/{swarmId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/consensus/approve/{swarmId} \
  -H 'Accept: application/problem+json'

PUT /api/v2/consensus/approve/{swarmId}

Approve the consensus with the given swarm ID

Parameters

Name In Type Required Description
swarmId path string true The swarm ID of the consensus to approve

Example responses

424 Response

{
  "detail": "string",
  "instance": "string",
  "status": 0,
  "timestamp": "string",
  "title": "string",
  "type": "string"
}

Responses

Status Meaning Description Schema
201 Created The consensus was approved None
424 Failed Dependency The consensus was not found. Note that this may occur if another party has already voted. ErrorResponse

consensus_reject

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/problem+json'
};

fetch('https://{instance}/api/v2/consensus/reject/{swarmId}',
{
  method: 'PUT',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/problem+json'
}

r = requests.put('https://{instance}/api/v2/consensus/reject/{swarmId}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/consensus/reject/{swarmId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/problem+json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/consensus/reject/{swarmId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/consensus/reject/{swarmId} \
  -H 'Accept: application/problem+json'

PUT /api/v2/consensus/reject/{swarmId}

Reject the consensus with the given swarm ID

Parameters

Name In Type Required Description
swarmId path string true The swarm ID of the consensus to approve

Example responses

424 Response

{
  "detail": "string",
  "instance": "string",
  "status": 0,
  "timestamp": "string",
  "title": "string",
  "type": "string"
}

Responses

Status Meaning Description Schema
201 Created The consensus was rejected None
424 Failed Dependency The consensus was not found. Note that this may occur if another party has already voted. ErrorResponse

approver-manifest

approver_manifest_get-all

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/approver/manifest',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/approver/manifest', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/approver/manifest");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/approver/manifest", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/approver/manifest \
  -H 'Accept: application/json'

GET /api/v2/approver/manifest

Get all manifest IDs

Example responses

200 Response

[
  "string"
]

Responses

Status Meaning Description Schema
200 OK All manifest IDs Inline

Response Schema

approver_manifest_get-all-details

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/approver/manifest-all',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/approver/manifest-all', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/approver/manifest-all");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/approver/manifest-all", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/approver/manifest-all \
  -H 'Accept: application/json'

GET /api/v2/approver/manifest-all

Get all manifests

Example responses

200 Response

[
  {
    "correlationId": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "finalised": true,
    "finalisedAt": "2019-08-24T14:15:22Z",
    "isAccepted": true,
    "requestId": "string",
    "swarmId": "string",
    "transfers": [
      {
        "accountId": "string",
        "accountType": "string",
        "amount": 0,
        "assetId": "string",
        "createdAt": "2019-08-24T14:15:22Z",
        "finalisedAt": "2019-08-24T14:15:22Z",
        "id": 0,
        "isAccepted": true,
        "isFinalised": true,
        "manifestCorrelationId": "string",
        "requestId": "string",
        "swarmId": "string",
        "tags": [
          "string"
        ],
        "transferCorrelationId": "string"
      }
    ]
  }
]

Responses

Status Meaning Description Schema
200 OK All manifests Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [ManifestDTO] false none [The manifest of a set of transfers.]
» correlationId string false none Correlation ID assigned by the client, if any.
» createdAt string(date-time) false none When this transaction was loaded into the database.
» finalised boolean false none Is the manifest finalised?
» finalisedAt string(date-time) false none Time at which the manifest was finalised, if it has been.
» isAccepted boolean false none Was the manifest accepted, rejected, or is it still undecided?. This is not present or null if it is undecided.
» requestId string false none Request ID assigned by the scheduler.
» swarmId string false none Swarm ID assigned by the Ledger-Swarm.
» transfers [TransferDTO] false none Transfers associated with this manifest.
»» accountId string true none The account ID
»» accountType string true none The account type
»» amount number true none The amount being transferred. This will be a floating point number.
»» assetId string true none The asset ID.
»» createdAt string(date-time) true none When the transfer was loaded. This is an ISO-8601 format timestamp
»» finalisedAt string(date-time) false none When the manifest was finalised, if it has been.
»» id integer(int64) true none The database record ID
»» isAccepted boolean false none Only present if the manifest is finalised. Was the manifest accepted?
»» isFinalised boolean true none Has the manifest been finalised?
»» manifestCorrelationId string true none The correlation ID associated with the manifest that contains the transfer.
»» requestId string true none The request ID associated with the manifest that contains the transfer
»» swarmId string true none The swarm ID associated with the manifest that contains the transfer
»» tags [string] false none Tags assigned to this transfer
»» transferCorrelationId string true none The correlation ID associated with the transfer

approver_manifest_get

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

fetch('https://{instance}/api/v2/approver/manifest/{id}',
{
  method: 'GET'

})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests

r = requests.get('https://{instance}/api/v2/approver/manifest/{id}')

print(r.json())
URL obj = new URL("https://{instance}/api/v2/approver/manifest/{id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/approver/manifest/{id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/approver/manifest/{id}

GET /api/v2/approver/manifest/{id}

Get a specific manifest

Parameters

Name In Type Required Description
id path string true The ID of the manifest to retrieve

Responses

Status Meaning Description Schema
200 OK The requested manifest None

approver_manifest_tags

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '[
  "string"
]';
const headers = {
  'Content-Type':'application/json'
};

fetch('https://{instance}/api/v2/approver/manifest/{id}/tags',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json'
}

r = requests.post('https://{instance}/api/v2/approver/manifest/{id}/tags', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/approver/manifest/{id}/tags");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://{instance}/api/v2/approver/manifest/{id}/tags", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X POST https://{instance}/api/v2/approver/manifest/{id}/tags \
  -H 'Content-Type: application/json'

POST /api/v2/approver/manifest/{id}/tags

Set tags on a manifest

Body parameter

[
  "string"
]

Parameters

Name In Type Required Description
id path string true The ID of the manifest
body body array[string] false The new tags

Responses

Status Meaning Description Schema
200 OK OK None

approver_manifest_transfer_tags

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '[
  "string"
]';
const headers = {
  'Content-Type':'application/json'
};

fetch('https://{instance}/api/v2/approver/manifest/{id}/{transfer}/tags',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json'
}

r = requests.post('https://{instance}/api/v2/approver/manifest/{id}/{transfer}/tags', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/approver/manifest/{id}/{transfer}/tags");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://{instance}/api/v2/approver/manifest/{id}/{transfer}/tags", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X POST https://{instance}/api/v2/approver/manifest/{id}/{transfer}/tags \
  -H 'Content-Type: application/json'

POST /api/v2/approver/manifest/{id}/{transfer}/tags

Set tags on a manifest

Body parameter

[
  "string"
]

Parameters

Name In Type Required Description
id path string true The ID of the manifest
transfer path integer(int32) true The index of the transfer
body body array[string] false The new tags

Responses

Status Meaning Description Schema
200 OK OK None

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '[
  "string"
]';
const headers = {
  'Content-Type':'application/json'
};

fetch('https://{instance}/api/v2/approver/manifest/{id}/{transfer}/{link}/tags',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json'
}

r = requests.post('https://{instance}/api/v2/approver/manifest/{id}/{transfer}/{link}/tags', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/approver/manifest/{id}/{transfer}/{link}/tags");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://{instance}/api/v2/approver/manifest/{id}/{transfer}/{link}/tags", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X POST https://{instance}/api/v2/approver/manifest/{id}/{transfer}/{link}/tags \
  -H 'Content-Type: application/json'

POST /api/v2/approver/manifest/{id}/{transfer}/{link}/tags

Set tags on a link

Body parameter

[
  "string"
]
Name In Type Required Description
id path string true The ID of the manifest
transfer path integer(int32) true The index of the transfer
link path integer(int32) true The index of the link
body body array[string] false The new tags
Status Meaning Description Schema
200 OK OK None

approver-rule

approver_rule_get-all

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/approver/rule',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/approver/rule', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/approver/rule");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/approver/rule", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/approver/rule \
  -H 'Accept: application/json'

GET /api/v2/approver/rule

Get all ledger rules

Example responses

200 Response

[
  {
    "id": 0,
    "name": "string",
    "priority": 0,
    "text": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK All rules Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [RuleDTO] false none none
» id integer(int64) false none none
» name string true none The rule's name
» priority integer(int32) false none The rule's priority (highest value first)
» text string true none The rule. The rule is a JEXL script that returns one of ACCEPT, REJECT, MANUAL, or ABSTAIN.

approver_rule_create

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "id": 0,
  "name": "string",
  "priority": 0,
  "text": "string"
}';
const headers = {
  'Content-Type':'application/json'
};

fetch('https://{instance}/api/v2/approver/rule',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json'
}

r = requests.put('https://{instance}/api/v2/approver/rule', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/approver/rule");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/approver/rule", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/approver/rule \
  -H 'Content-Type: application/json'

PUT /api/v2/approver/rule

Add a new ledger rule

Body parameter

{
  "id": 0,
  "name": "string",
  "priority": 0,
  "text": "string"
}

Parameters

Name In Type Required Description
body body RuleDTO false The new rule

Responses

Status Meaning Description Schema
200 OK OK None

approver_rule_delete

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

fetch('https://{instance}/api/v2/approver/rule/{id}',
{
  method: 'DELETE'

})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests

r = requests.delete('https://{instance}/api/v2/approver/rule/{id}')

print(r.json())
URL obj = new URL("https://{instance}/api/v2/approver/rule/{id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://{instance}/api/v2/approver/rule/{id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X DELETE https://{instance}/api/v2/approver/rule/{id}

DELETE /api/v2/approver/rule/{id}

Delete a ledger rule

Parameters

Name In Type Required Description
id path integer(int64) true The ID of the rule to delete

Responses

Status Meaning Description Schema
200 OK OK None

router

Get all routes

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/router/route',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/router/route', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/router/route");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/router/route", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/router/route \
  -H 'Accept: application/json'

GET /api/v2/router/route

Get all routes

Example responses

200 Response

[
  {
    "account": "string",
    "asset": "string",
    "domain": "string",
    "id": 0,
    "match": "/UK\\d{4}-\\w{6}/",
    "participant": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK All routes Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [RouteSpec] false none none
» account string true none The account to route via at the remote participant
» asset string true none The asset to route. Empty string matches all.
» domain string false none The domain to route to. Defaults to same domain as this participant.
» id integer(int64) false read-only The ID of the route.
» match string false none Regular expression or Literal to match the account. Empty string matches all. Defaults to matching all.
The value is interpreted as a regular expression if it starts and ends with a solidus character ('/').
Both regular expressions and literals are matched against the entire account ID.

For example:
"UK01." matches only the account ID "UK1.". The dot and star are literals, not patterns.
"/UK[0-9]{2}.*/" matches any account ID that starts with "UK" followed by two digits then any characters.
» participant string true none The participant to route to. Required.

Create a route

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "account": "string",
  "asset": "string",
  "domain": "string",
  "match": "/UK\\d{4}-\\w{6}/",
  "participant": "string"
}';
const headers = {
  'Content-Type':'application/json'
};

fetch('https://{instance}/api/v2/router/route',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json'
}

r = requests.put('https://{instance}/api/v2/router/route', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/router/route");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/router/route", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/router/route \
  -H 'Content-Type: application/json'

PUT /api/v2/router/route

Create a route

Body parameter

{
  "account": "string",
  "asset": "string",
  "domain": "string",
  "match": "/UK\\d{4}-\\w{6}/",
  "participant": "string"
}

Parameters

Name In Type Required Description
body body RouteSpec true none

Responses

Status Meaning Description Schema
200 OK The route that was created. None

Query for matching routes

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/router/route/query',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/router/route/query', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/router/route/query");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/router/route/query", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/router/route/query \
  -H 'Accept: application/json'

GET /api/v2/router/route/query

Query for routes that match an account and asset

Parameters

Name In Type Required Description
asset query string false The asset to route
account query string false The account to route

Example responses

200 Response

[
  {
    "account": "string",
    "asset": "string",
    "domain": "string",
    "id": 0,
    "match": "/UK\\d{4}-\\w{6}/",
    "participant": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK All matching routes Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [RouteSpec] false none none
» account string true none The account to route via at the remote participant
» asset string true none The asset to route. Empty string matches all.
» domain string false none The domain to route to. Defaults to same domain as this participant.
» id integer(int64) false read-only The ID of the route.
» match string false none Regular expression or Literal to match the account. Empty string matches all. Defaults to matching all.
The value is interpreted as a regular expression if it starts and ends with a solidus character ('/').
Both regular expressions and literals are matched against the entire account ID.

For example:
"UK01." matches only the account ID "UK1.". The dot and star are literals, not patterns.
"/UK[0-9]{2}.*/" matches any account ID that starts with "UK" followed by two digits then any characters.
» participant string true none The participant to route to. Required.

Delete a route

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/problem+json'
};

fetch('https://{instance}/api/v2/router/route/{id}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/problem+json'
}

r = requests.delete('https://{instance}/api/v2/router/route/{id}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/router/route/{id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/problem+json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://{instance}/api/v2/router/route/{id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X DELETE https://{instance}/api/v2/router/route/{id} \
  -H 'Accept: application/problem+json'

DELETE /api/v2/router/route/{id}

Delete a route

Parameters

Name In Type Required Description
id path integer(int64) true The ID of the route

Example responses

424 Response

{
  "detail": "string",
  "instance": "string",
  "status": 0,
  "timestamp": "string",
  "title": "string",
  "type": "string"
}

Responses

Status Meaning Description Schema
204 No Content The route was deleted None
424 Failed Dependency The route does not exist ErrorResponse

Get a route

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

fetch('https://{instance}/api/v2/router/route/{id}',
{
  method: 'GET'

})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests

r = requests.get('https://{instance}/api/v2/router/route/{id}')

print(r.json())
URL obj = new URL("https://{instance}/api/v2/router/route/{id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/router/route/{id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/router/route/{id}

GET /api/v2/router/route/{id}

Get a route

Parameters

Name In Type Required Description
id path integer(int64) true The ID of the route

Responses

Status Meaning Description Schema
200 OK The route None
424 Failed Dependency The route does not exist None

Query for the route a transaction will take

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "manifestId": "string",
  "transfers": [
    {
      "amount": 0,
      "assetId": "string",
      "from": {
        "account": "string",
        "domain": "string",
        "participant": "string"
      },
      "to": {
        "account": "string",
        "domain": "string",
        "participant": "string"
      },
      "transferId": "string"
    }
  ]
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/router',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

r = requests.post('https://{instance}/api/v2/router', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/router");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://{instance}/api/v2/router", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X POST https://{instance}/api/v2/router \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json'

POST /api/v2/router

Query for the route a transaction will take

Body parameter

{
  "manifestId": "string",
  "transfers": [
    {
      "amount": 0,
      "assetId": "string",
      "from": {
        "account": "string",
        "domain": "string",
        "participant": "string"
      },
      "to": {
        "account": "string",
        "domain": "string",
        "participant": "string"
      },
      "transferId": "string"
    }
  ]
}

Parameters

Name In Type Required Description
body body Proposal false The transaction to test

Example responses

200 Response

[
  {
    "account": "string",
    "asset": "string",
    "domain": "string",
    "id": 0,
    "match": "/UK\\d{4}-\\w{6}/",
    "participant": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK All matching routes Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [RouteSpec] false none none
» account string true none The account to route via at the remote participant
» asset string true none The asset to route. Empty string matches all.
» domain string false none The domain to route to. Defaults to same domain as this participant.
» id integer(int64) false read-only The ID of the route.
» match string false none Regular expression or Literal to match the account. Empty string matches all. Defaults to matching all.
The value is interpreted as a regular expression if it starts and ends with a solidus character ('/').
Both regular expressions and literals are matched against the entire account ID.

For example:
"UK01." matches only the account ID "UK1.". The dot and star are literals, not patterns.
"/UK[0-9]{2}.*/" matches any account ID that starts with "UK" followed by two digits then any characters.
» participant string true none The participant to route to. Required.

Get all observers

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/router/observer/{id}',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/router/observer/{id}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/router/observer/{id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/router/observer/{id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/router/observer/{id} \
  -H 'Accept: application/json'

GET /api/v2/router/observer/{id}

Get an observer by id

Parameters

Name In Type Required Description
id path string true The id of the observer record

Example responses

200 Response

[
  {
    "id": 0,
    "account": "string",
    "domain": "string",
    "participant": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK All routes Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [ObserverDTO] false none none
» id integer(int64) false none none
» account string true none The the account to be observed
» domain string true none the domain of the observer participant
» participant string true none The participant observing

Create a observer

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "account": "string",
  "domain": "string",
  "participant": "string"
}';
const headers = {
  'Content-Type':'application/json'
};

fetch('https://{instance}/api/v2/router/observer',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json'
}

r = requests.put('https://{instance}/api/v2/router/observer', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/router/observer");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v2/router/observer", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v2/router/observer \
  -H 'Content-Type: application/json'

PUT /api/v2/router/observer

Create an observer

Body parameter

{
  "account": "string",
  "domain": "string",
  "participant": "string"
}

Parameters

Name In Type Required Description
body body ObserverUpdate true none

Responses

Status Meaning Description Schema
200 OK The observer that was created. None

Delete an observer

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/router/observer/{id}',
{
  method: 'DELETE',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.delete('https://{instance}/api/v2/router/observer/{id}', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/router/observer/{id}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "https://{instance}/api/v2/router/observer/{id}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X DELETE https://{instance}/api/v2/router/observer/{id} \
  -H 'Accept: application/json'

DELETE /api/v2/router/observer/{id}

Delete an observer by id

Parameters

Name In Type Required Description
id path string true The id of the observer record

Example responses

200 Response

[
  {
    "id": 0,
    "account": "string",
    "domain": "string",
    "participant": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK All routes Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [ObserverDTO] false none none
» id integer(int64) false none none
» account string true none The the account to be observed
» domain string true none the domain of the observer participant
» participant string true none The participant observing

Query observers

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v2/router/observer/query',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v2/router/observer/query', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v2/router/observer/query");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v2/router/observer/query", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v2/router/observer/query \
  -H 'Accept: application/json'

GET /api/v2/router/observer/query

Query observers

Parameters

Name In Type Required Description
account query string false the account being observed
domain query string false the domain of the observer
participant query string false the participant observing

Example responses

200 Response

[
  {
    "id": 0,
    "account": "string",
    "domain": "string",
    "participant": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK All routes Inline

Response Schema

Status Code 200

Name Type Required Restrictions Description
anonymous [ObserverDTO] false none none
» id integer(int64) false none none
» account string true none The the account to be observed
» domain string true none the domain of the observer participant
» participant string true none The participant observing

account-type

v3_account-type_create

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const inputBody = '{
  "amount": 0,
  "isDelta": true,
  "reason": "string"
}';
const headers = {
  'Content-Type':'application/json'
};

fetch('https://{instance}/api/v3/account-type',
{
  method: 'PUT',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Content-Type': 'application/json'
}

r = requests.put('https://{instance}/api/v3/account-type', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v3/account-type");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://{instance}/api/v3/account-type", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X PUT https://{instance}/api/v3/account-type \
  -H 'Content-Type: application/json'

PUT /api/v3/account-type

Create an account type. Note: Account types are immutable once created.

Body parameter

{
  "amount": 0,
  "isDelta": true,
  "reason": "string"
}

Parameters

Name In Type Required Description
body body AccountBalanceUpdate false The authentication request

Responses

Status Meaning Description Schema
201 Created Account type was created None
204 No Content Account type existed already, but matched the specification provided. None
409 Conflict Account type already existed and differs from the specification. It cannot be changed nor deleted now. None

v3_account-type_get

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

fetch('https://{instance}/api/v3/account-type/{accountType}',
{
  method: 'GET'

})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests

r = requests.get('https://{instance}/api/v3/account-type/{accountType}')

print(r.json())
URL obj = new URL("https://{instance}/api/v3/account-type/{accountType}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v3/account-type/{accountType}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v3/account-type/{accountType}

GET /api/v3/account-type/{accountType}

Get an account type

Parameters

Name In Type Required Description
accountType path string true The account type

Responses

Status Meaning Description Schema
200 OK Account type fetched None
424 Failed Dependency Account type did not exist. None

nostro-vostro

v3_nostro-vostro

Warning

You need to include a basic Authorization header in the code examples below

replace {instance} with the name of your instance

Code samples

const headers = {
  'Accept':'application/json'
};

fetch('https://{instance}/api/v3/nostro-vostro',
{
  method: 'GET',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
import requests
headers = {
  'Accept': 'application/json'
}

r = requests.get('https://{instance}/api/v3/nostro-vostro', headers = headers)

print(r.json())
URL obj = new URL("https://{instance}/api/v3/nostro-vostro");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/json"},
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://{instance}/api/v3/nostro-vostro", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}
# You can also use wget
curl -X GET https://{instance}/api/v3/nostro-vostro \
  -H 'Accept: application/json'

GET /api/v3/nostro-vostro

Get all account IDs.

Example responses

200 Response

[
  "string"
]

Responses

Status Meaning Description Schema
200 OK List of account N-V mappings Inline

Response Schema

Schemas

AccountBalanceUpdate

{
  "amount": 0,
  "isDelta": true,
  "reason": "string"
}

Properties

Name Type Required Restrictions Description
amount number false none none
isDelta boolean false none none
reason string false none none

ObserverUpdate

{
  "account": "string",
  "domain": "string",
  "participant": "string"
}

Properties

Name Type Required Restrictions Description
account string false none none
domain string false none none
participant string false none none

AccountDTO

{
  "accountId": "string",
  "accountType": "string",
  "assetId": "string",
  "balances": [
    {
      "amount": 0,
      "label": "string"
    }
  ],
  "external": true,
  "hotBalance": 0,
  "lastProposalAt": "2019-08-24T14:15:22Z",
  "lastSettledAt": "2019-08-24T14:15:22Z",
  "liability": true,
  "settledBalance": 0
}

An account and asset combination

Properties

Name Type Required Restrictions Description
accountId string false none The account ID
accountType string false none The account's type. This is part of the accounts full identifier.
assetId string false none The asset ID
balances [BalanceDTO] false none The balances associated with the account.
external boolean false none none
hotBalance number false none The 'hot' balance, which assumes all pending transactions succeed. (A floating point number). May be null if the ledger implementation does not support it.
lastProposalAt string(date-time) false none Time of the last proposed transaction or finalisation.
lastSettledAt string(date-time) false none The time of the last settled balance update.
liability boolean false none none
settledBalance number false none The 'settled' balance, which ignores all pending transactions. (A floating point number). May be null if the ledger implementation does not support it.

AccountId

{
  "accountId": "string",
  "accountType": "string"
}

Properties

Name Type Required Restrictions Description
accountId string false none The account ID
accountType string false none The account type

AccountTypeDTO

{
  "external": true,
  "liability": true,
  "name": "string"
}

An account type

Properties

Name Type Required Restrictions Description
external boolean false none none
liability boolean false none none
name string false none The unique name of the account type

AuthRequest

{
  "password": "cheese000!!",
  "userName": "user123"
}

Pass username and password to the login API to retrieve a bearer token

Properties

Name Type Required Restrictions Description
password string true none The password
userName string true none The user name

AuthResponse

{
  "flags": [
    {
      "name": "string",
      "value": true
    }
  ],
  "token": "string"
}

Response to an authorisation request

Properties

Name Type Required Restrictions Description
flags [NamedFlag] false none A list of tags that indicate the capabilities of the user
token string false none A JWT token for use as a bearer authorisation

BalanceDTO

{
  "amount": 0,
  "label": "string"
}

The balances associated with the account.

Properties

Name Type Required Restrictions Description
amount number false none The amount of the balance, if available
label string false none The label for this balance type

BalanceData

{
  "accountId": "string",
  "assetId": "string",
  "balances": [
    {
      "amount": 0,
      "label": "string"
    }
  ],
  "hotBalance": 0,
  "settledBalance": 0
}

The balance data, if available.

Properties

Name Type Required Restrictions Description
accountId string false none The account ID
assetId string false none The asset ID
balances [BalanceDTO] false none The balances associated with the account.
hotBalance number false none The 'hot' balance, which assumes all pending transactions succeed. (A floating point number). May be null if the ledger implementation does not support it.
settledBalance number false none The 'settled' balance, which ignores all pending transactions. (A floating point number). May be null if the ledger implementation does not support it.

ConsensusDTO

{
  "consensus": "string",
  "finalisedAt": "2019-08-24T14:15:22Z",
  "finalisedStatus": "APPROVED",
  "receivedAt": "2019-08-24T14:15:22Z",
  "swarmId": "string",
  "tags": [
    "string"
  ]
}

Properties

Name Type Required Restrictions Description
consensus string false none none
finalisedAt string(date-time) false none none
finalisedStatus string false none none
receivedAt string(date-time) false none none
swarmId string false none none
tags [string] false none none

Enumerated Values

Property Value
finalisedStatus APPROVED
finalisedStatus REJECTED
finalisedStatus EXPIRED
finalisedStatus UNRECOGNIZED

ErrorResponse

{
  "detail": "string",
  "instance": "string",
  "status": 0,
  "timestamp": "string",
  "title": "string",
  "type": "string"
}

An RFC-9457 standard error response.

Properties

Name Type Required Restrictions Description
detail string false none Human-readable explanation specific to this occurrence of the problem.
instance string false none A URI reference that identifies the specific occurrence of the problem.
status integer(int32) false none The HTTP status code.
timestamp string false none The time the error occurred.
title string false none A short human-readable summary of the problem.
type string false none A URI reference that identifies the problem type.

HttpMethod

{}

Properties

None

HttpStatusCode

{
  "error": true,
  "is1xxInformational": true,
  "is2xxSuccessful": true,
  "is3xxRedirection": true,
  "is4xxClientError": true,
  "is5xxServerError": true
}

Properties

Name Type Required Restrictions Description
error boolean false none none
is1xxInformational boolean false none none
is2xxSuccessful boolean false none none
is3xxRedirection boolean false none none
is4xxClientError boolean false none none
is5xxServerError boolean false none none

KafkaHeaderDTO

{
  "name": "string",
  "textValue": "string"
}

A header on a Kafka message

Properties

Name Type Required Restrictions Description
name string false none The name of the header
textValue string false none The value of the header as a string

KafkaRecordDTO

{
  "correlationId": "string",
  "envelopeText": "string",
  "headers": [
    {
      "name": "string",
      "textValue": "string"
    }
  ],
  "receivedAt": "2019-08-24T14:15:22Z",
  "recordKey": "string",
  "requestId": "string",
  "swarmId": "string",
  "type": "string"
}

A Kafka message with standard LedgerSwarm headers

Properties

Name Type Required Restrictions Description
correlationId string false none The correlation ID of the message
envelopeText string false none Textual representation of the Kafka message, assuming it contained a LedgerSwarm Envelope.
headers [KafkaHeaderDTO] false none The headers on the message
receivedAt string(date-time) false none The time the message was received
recordKey string false none The Kafka record key of the message
requestId string false none The request ID associated with the message.
swarmId string false none The swarm ID associated with the message.
type string false none The type of the message.

LinkDTO

{
  "account": {
    "accountId": "string",
    "accountType": "string",
    "assetId": "string",
    "balances": [
      {
        "amount": 0,
        "label": "string"
      }
    ],
    "external": true,
    "hotBalance": 0,
    "lastProposalAt": "2019-08-24T14:15:22Z",
    "lastSettledAt": "2019-08-24T14:15:22Z",
    "liability": true,
    "settledBalance": 0
  },
  "action": "UNKNOWN",
  "index": 0,
  "tags": [
    "string"
  ]
}

Links that constitute this transfer.

Properties

Name Type Required Restrictions Description
account AccountDTO false none An account and asset combination
action string false none none
index integer(int32) false none The index of this link in the transfer
tags [string] false none Tags assigned to this link

Enumerated Values

Property Value
action UNKNOWN
action DEBIT
action CREDIT
action UNRECOGNIZED

ManifestDTO

{
  "correlationId": "string",
  "createdAt": "2019-08-24T14:15:22Z",
  "finalised": true,
  "finalisedAt": "2019-08-24T14:15:22Z",
  "isAccepted": true,
  "requestId": "string",
  "swarmId": "string",
  "transfers": [
    {
      "accountId": "string",
      "accountType": "string",
      "amount": 0,
      "assetId": "string",
      "createdAt": "2019-08-24T14:15:22Z",
      "finalisedAt": "2019-08-24T14:15:22Z",
      "id": 0,
      "isAccepted": true,
      "isFinalised": true,
      "manifestCorrelationId": "string",
      "requestId": "string",
      "swarmId": "string",
      "tags": [
        "string"
      ],
      "transferCorrelationId": "string"
    }
  ]
}

The manifest of a set of transfers.

Properties

Name Type Required Restrictions Description
correlationId string false none Correlation ID assigned by the client, if any.
createdAt string(date-time) false none When this transaction was loaded into the database.
finalised boolean false none Is the manifest finalised?
finalisedAt string(date-time) false none Time at which the manifest was finalised, if it has been.
isAccepted boolean false none Was the manifest accepted, rejected, or is it still undecided?. This is not present or null if it is undecided.
requestId string false none Request ID assigned by the scheduler.
swarmId string false none Swarm ID assigned by the Ledger-Swarm.
transfers [TransferDTO] false none Transfers associated with this manifest.

NV

{
  "nostro": {
    "accountId": "string",
    "accountType": "string"
  },
  "vostro": {
    "accountId": "string",
    "domain": "string",
    "participantId": "string"
  }
}

Properties

Name Type Required Restrictions Description
nostro AccountId false none none
vostro VostroId false none none

NamedFlag

{
  "name": "string",
  "value": true
}

A flag that indicates the capabilities of the user

Properties

Name Type Required Restrictions Description
name string false none Name of the flag
value boolean false none Value of the flag

NewPassword

{
  "newPassword": "string",
  "oldPassword": "string"
}

Input to a user's password change request

Properties

Name Type Required Restrictions Description
newPassword string true none The new password
oldPassword string true none The old password. Must be specified to prevent abuse of leaked bearer token.

PacsResponse

{
  "error": "string",
  "manifestId": "string",
  "status": "string"
}

Properties

Name Type Required Restrictions Description
error string false none none
manifestId string false none none
status string false none none

Party

{
  "account": "string",
  "domain": "string",
  "participant": "string"
}

A party in the proposed transfer

Properties

Name Type Required Restrictions Description
account string true none The account ID
domain string true none The participant's domain
participant string true none The participant's ID

PingResponse

{
  "timestamp": "2019-08-24T14:15:22Z",
  "user": "string"
}

Properties

Name Type Required Restrictions Description
timestamp string(date-time) false none none
user string false none none

PropertiesResponse

{
  "context": "string",
  "instance": "string",
  "domain": "string",
  "id": "string",
  "cluster": "string"
}

Properties

Name Type Required Restrictions Description
context string false none none
instance string false none none
domain string false none none
id string false none none
cluster string false none none

Proposal

{
  "manifestId": "string",
  "transfers": [
    {
      "amount": 0,
      "assetId": "string",
      "from": {
        "account": "string",
        "domain": "string",
        "participant": "string"
      },
      "to": {
        "account": "string",
        "domain": "string",
        "participant": "string"
      },
      "transferId": "string"
    }
  ]
}

A new proposal

Properties

Name Type Required Restrictions Description
manifestId string false none The proposal's correlation ID. This becomes the manifest correlation ID.
transfers [ProposedTransfer] true none The new transfers

ProposalResponse

{
  "manifestId": "string",
  "transferIds": [
    "string"
  ]
}

The ID of the manifest and transfers proposed

Properties

Name Type Required Restrictions Description
manifestId string false none The ID of the manifest proposed
transferIds [string] false none The IDs of the transfers proposed

ProposedTransfer

{
  "amount": 0,
  "assetId": "string",
  "from": {
    "account": "string",
    "domain": "string",
    "participant": "string"
  },
  "to": {
    "account": "string",
    "domain": "string",
    "participant": "string"
  },
  "transferId": "string"
}

A proposed transfer within the proposal

Properties

Name Type Required Restrictions Description
amount number true none none
assetId string true none none
from Party false none A party in the proposed transfer
to Party false none A party in the proposed transfer
transferId string false none none

RouteSpec

{
  "account": "string",
  "asset": "string",
  "domain": "string",
  "id": 0,
  "match": "/UK\\d{4}-\\w{6}/",
  "participant": "string"
}

Properties

Name Type Required Restrictions Description
account string true none The account to route via at the remote participant
asset string true none The asset to route. Empty string matches all.
domain string false none The domain to route to. Defaults to same domain as this participant.
id integer(int64) false read-only The ID of the route.
match string false none Regular expression or Literal to match the account. Empty string matches all. Defaults to matching all.
The value is interpreted as a regular expression if it starts and ends with a solidus character ('/').
Both regular expressions and literals are matched against the entire account ID.

For example:
"UK01." matches only the account ID "UK1.". The dot and star are literals, not patterns.
"/UK[0-9]{2}.*/" matches any account ID that starts with "UK" followed by two digits then any characters.
participant string true none The participant to route to. Required.

RuleDTO

{
  "id": 0,
  "name": "string",
  "priority": 0,
  "text": "string"
}

Properties

Name Type Required Restrictions Description
id integer(int64) false none none
name string true none The rule's name
priority integer(int32) false none The rule's priority (highest value first)
text string true none The rule. The rule is a JEXL script that returns one of ACCEPT, REJECT, MANUAL, or ABSTAIN.

ObserverDTO

{
  "id": 0,
  "account": "string",
  "domain": "string",
  "participant": "string"
}

Properties

Name Type Required Restrictions Description
id integer(int64) false none none
account string true none The the account to be observed
domain string true none the domain of the observer participant
participant string true none The participant observing

StandardAccountId

{
  "accountId": "string",
  "accountType": "string"
}

Properties

Name Type Required Restrictions Description
accountId string true none The account ID
accountType string true none The account type

TransferDTO

{
  "accountId": "string",
  "accountType": "string",
  "amount": 0,
  "assetId": "string",
  "createdAt": "2019-08-24T14:15:22Z",
  "finalisedAt": "2019-08-24T14:15:22Z",
  "id": 0,
  "isAccepted": true,
  "isFinalised": true,
  "manifestCorrelationId": "string",
  "requestId": "string",
  "swarmId": "string",
  "tags": [
    "string"
  ],
  "transferCorrelationId": "string"
}

A credit or debit resulting from a transfer

Properties

Name Type Required Restrictions Description
accountId string true none The account ID
accountType string true none The account type
amount number true none The amount being transferred. This will be a floating point number.
assetId string true none The asset ID.
createdAt string(date-time) true none When the transfer was loaded. This is an ISO-8601 format timestamp
finalisedAt string(date-time) false none When the manifest was finalised, if it has been.
id integer(int64) true none The database record ID
isAccepted boolean false none Only present if the manifest is finalised. Was the manifest accepted?
isFinalised boolean true none Has the manifest been finalised?
manifestCorrelationId string true none The correlation ID associated with the manifest that contains the transfer.
requestId string true none The request ID associated with the manifest that contains the transfer
swarmId string true none The swarm ID associated with the manifest that contains the transfer
tags [string] false none Tags assigned to this transfer
transferCorrelationId string true none The correlation ID associated with the transfer

UserData

{
  "admin": true,
  "userName": "string"
}

A user

Properties

Name Type Required Restrictions Description
admin boolean false none Is the user an administrator? Defaults to false if omitted.
userName string true none The user's name.

UserUpdate

{
  "isAdmin": true,
  "password": "string"
}

Input to updating a user

Properties

Name Type Required Restrictions Description
isAdmin boolean false none If specified, change the user from an administrator to a regular user and back again.
password string false none If specified, change the user's password. Note: this field is required when creating a new user.

VostroId

{
  "accountId": "string",
  "domain": "string",
  "participantId": "string"
}

Properties

Name Type Required Restrictions Description
accountId string false none none
domain string false none none
participantId string false none none