Query withdrawals
Retrieving all your withdrawals
const bodyJSON = {
variables: {
input: {
},
},
query: `
query ($input: WithdrawalQueryInput!) {
withdrawals(input: $input) {
id
recipient {
firstName lastName
}
}
}`,
}; query($input: WithdrawalQueryInput!) {
withdrawals(input: $input) {
id
recipient {
firstName
lastName
}
# there are many other properties
}
}{
"input": {
}
}{
"data": {
"withdrawals": [
{
"id": "5b04c62ec0bf606bf216ae21",
"recipient": {
"firstName": "John"
"lastName": "Smith"
}
},
{
"id": "5b04c6bfc0bf606bf216af06",
"recipient": {
"firstName": "John"
"lastName": "Smith"
}
},
{
"id": "5b04c8e3c0bf606bf216b026",
"recipient": {
"firstName": "John"
"lastName": "Smith"
}
}
]
}
}Retrieving some of your withdrawals
const bodyJSON = {
variables: {
input: {
statuses: "CONFIRMED",
maxCreatedAt: "2020-01-29",
},
},
query: `
query ($input: WithdrawalQueryInput!) {
withdrawals(input: $input) {
id createdAt
}
}`,
}; query($input: WithdrawalQueryInput!) {
withdrawals(input: $input) {
id
createdAt
# there are many other properties
}
}{
# there are more query parameters available, see the API schema
"input": {
"statuses": "CONFIRMED",
"maxCreatedAt": "2020-01-29"
}
}{
"data": {
"withdrawals": [
{
"id": "5b04c62ec0bf606bf216ae21",
"createdAt": "2020-01-17T07:21:20.247Z"
},
{
"id": "5b04c6bfc0bf606bf216af06",
"createdAt": "2018-08-13T05:45:28.698Z"
}
]
}
}Retrieving a single withdrawal
const bodyJSON = {
variables: {
input: "5b04c62ec0bf606bf216ae21",
},
query: `
query ($input: ID) {
withdrawal(id: $input) {
status createdAt amount
}
}`,
};query($input: ID) {
withdrawal(id: $input) {
status
createdAt
amount
# there are many other properties
}
}{
# there are more query parameters available, see the API schema
"input": "5b04c62ec0bf606bf216ae21"
}{
"data": {
"withdrawal": {
"status": "CONFIRMED",
"createdAt": "2020-01-17T07:21:20.247Z",
"amount": 1000
}
}
}Last updated
Was this helpful?