Delphi (ActiveX) / Marketplacer SELLER API / Node Query for (Multiple) Orders
Back to Collection Items
var
begin
http.BasicAuth := 1;http.Login := '{{username}}';http.Password := '{{password}}';json.UpdateString('query','query GetOrdersById($ids: [ID!]!){' + #10 + ' nodes(ids: $ids)' + #10 + ' {' + #10 + ' ... on Order {' + #10 + ' __typename' + #10 + ' id' + #10 + ' status' + #10 + ' }' + #10 + ' }' + #10 + '}');json.UpdateString('variables','{' + #10 + ' "ids": [' + #10 + ' "T3JkZXItMTAwMDA=",' + #10 + ' "T3JkZXItMTAwNjk=",' + #10 + ' "T3JkZXItMTAwNzQ="' + #10 + ' ]' + #10 + '}');
Curl Command
curl -X POST
-u '{{username}}:{{password}}'
-H "MARKETPLACER-API-KEY: {{api_key}}"
-H "Content-Type: application/json"
--data-raw '{"query":"query GetOrdersById($ids: [ID!]!){\n nodes(ids: $ids)\n {\n ... on Order {\n __typename\n id\n status\n }\n }\n}","variables":"{\n\t\"ids\": [\n\t\t\"T3JkZXItMTAwMDA=\",\n\t\t\"T3JkZXItMTAwNjk=\",\n\t\t\"T3JkZXItMTAwNzQ=\"\n\t]\n}"}'
https://bestfriendbazaar.com/graphql
Postman Collection Item JSON
{
"name": "Node Query for (Multiple) Orders",
"request": {
"method": "POST",
"header": [
{
"key": "MARKETPLACER-API-KEY",
"value": "{{api_key}}",
"type": "text"
},
{
"key": "Content-Type",
"value": "application/json",
"type": "text"
}
],
"body": {
"mode": "graphql",
"graphql": {
"query": "query GetOrdersById($ids: [ID!]!){\n nodes(ids: $ids)\n {\n ... on Order {\n __typename\n id\n status\n }\n }\n}",
"variables": "{\n\t\"ids\": [\n\t\t\"T3JkZXItMTAwMDA=\",\n\t\t\"T3JkZXItMTAwNjk=\",\n\t\t\"T3JkZXItMTAwNzQ=\"\n\t]\n}"
}
},
"url": {
"raw": "{{base_url}}",
"host": [
"{{base_url}}"
],
"path": null
},
"description": null
},
"response": [
]
}