Quick Exchange
  • Quick Exchange for Partners
  • Expired Quote Handling
  • Widget Integration
    • Embedded Widget
    • Configuration
      • Config Version
      • Settlement Defaults
      • Settlement Parameters
      • Custom Styles
      • Identity
      • Special Layout
      • Partner Fields
    • Event Hooks
  • API Integration
    • Authentication
    • User Session
      • OAuth
      • KYC
    • Settlements
  • Settlements
    • Funding Methods
      • BLOCKCHAIN_TRANSFER
      • BLOCKCHAIN_DELEGATED_BROADCAST
      • CARD_PAYMENT
        • Test Cards
    • Payout Methods
      • BLOCKCHAIN_TRANSFER
      • LIQUID_PARTNER_WALLET
      • LIQUID_WALLET
      • LIQUID_USER_WALLET
  • E-Commerce
    • X-Quoine-Auth
    • Intents (Fixed Settlements)
      • Deliverable Currency
    • Transactions
      • Transaction Status
Powered by GitBook
On this page
  • Fetch Transactions
  • Swagger
  • X-Quoine-Auth
  • Example (Javascript)
  • Pagination

Was this helpful?

  1. E-Commerce

Transactions

Partners can fetch the history of transactions associated with their API key.

PreviousDeliverable CurrencyNextTransaction Status

Last updated 3 years ago

Was this helpful?

Query results may be truncated. Queries are limited to 100 results. Please see at the bottom of page.

Fetch Transactions

GET https://partners.liquid.com/api/v1/partner/{public_api_key}/transactions

Path Parameters

Name
Type
Description

public_api_key

string

Public API key of the partner.

Query Parameters

Name
Type
Description

min_ts

number

Unix millisecond timestamp.

max_ts

number

Unix millisecond timestamp.

status

string

Transaction status.

intent_id

string

Search by Intent.

partner_order_id

string

Searchable 40 character id.

partner_tag

string

Filter for transactions containing a specified tag.

Headers

Name
Type
Description

X-Quoine-Auth

string

Signed JWT belonging to the Liquid user account associated with the partner.

{
    "success": true,
    "environment": "SANDBOX",
    "message": "Partner Transactions.",
    "payload": [
        {
            "id": "1664961c-a190-48cf-b787-5b85fd5bfc75",
            "intent_id": "f53762a1-3ca4-4224-8f49-41caf86baba9",
            "created_at": "1618978440482",
            "public_api_key": "pk_sandbox_3ded0834-6bc5-4442-86ec-bd1fb96a075e",
            "partner_order_id": "max 40 chars",
            "partner_ref": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c",
            "reputation_identity_id": "e74b7962-75c5-40eb-9724-1ff8189c9ad8",
            "status": "FILLED",
            "outcome_category": "FILLED",
            "funding_settlement": {
                "currency": "USD",
                "quantity": "50.00"
            },
            "payout_settlement": {
                "currency": "BTC",
                "quantity": "0.0014150"
            },
            "approximate_usd_equivalent": "50.00"
        }
    ],
    "selection": {        
        "payload_min_ts": 1619978440482,
        "payload_max_ts": 1619978440482,
        "payload_count": 100,
        
        "range_min_ts": 1618978400000,
        "range_max_ts": 1618978850000,
        "range_count": 497,
        
        "total_min_ts": 1618978440482,
        "total_max_ts": 1623109714598,
        "total_count": 47567
    }
}

Swagger

X-Quoine-Auth

Encoded payload must contain:

{
    "token_id": "{created in Liquid web app, link above}",
    "path": "/realtime",
    "delegate_path": "/api/v1/partner/{public_api_key}/transactions",
    "nonce": {current unix timestamp}
}

Example (Javascript)

const jwt = require("jwt-simple");
const axios = require("axios");

const tokenId = "";
const tokenSecret =  "";
const publicApiKey = "pk_xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx";

const path = `/api/v1/partner/${publicApiKey}/transactions`;
const apiBase = "https://partners.liquid.com";

const xQuoineAuth = jwt.encode(
  {
    token_id: tokenId,
    path: "/realtime",
    delegate_path: path,
    nonce: Date.now(),
  },
  tokenSecret
);

axios
  .get(apiBase + path + "?min_ts=1623165462000&status=FILLED", {
    headers: {
      "X-Quoine-Auth": xQuoineAuth,
    },
  })
  .then((response) => {
    console.log(response.data);
  })
  .catch((err) => console.log(err));

Pagination

The selection object returned in the query contains information about:

  • How many transactions exist for the given partner (total_*)

  • How many transactions are responsive to the given query (range_*)

  • How many transactions were actually returned in the payload (payload_*)

"selection": {
    "payload_min_ts": 1621417624122,
    "payload_max_ts": 1623231033118,
    "payload_count": 46,
    "range_min_ts": 1620639114127,
    "range_max_ts": 1623231114127,
    "range_count": 46,
    "total_max_ts": 1623231033118,
    "total_min_ts": 1618978440482,
    "total_count": 57
}

If the payload_count is less than the range_count then results are being hidden. A new query should be made again form min_ts={payload_max_ts + 1}.

Signed JWT.

https://partners.liquid.com/swagger/#/default/get_api_v1_partner__public_api_key__transactions
Please refer to auth token instructions.
Pagination