Skip to main content

Create Sell Transaction

POST 

/transactions/sell

Initiate a transaction to sell the specified crypto currency and send the requested fiat currency to the specified payout method. Allows for sending form data to submit a payment method.

Request

Header Parameters

    Api-Signature string

    Digitally signed JWT.

Body

required
    CryptoCurrency CryptoCurrencyCode (string)required

    Cryptocurrency code:

    • BTC
    • USDC
    Example: BTC
    FiatAmount PositiveDecimal (string)required

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    CryptoAuthorizedAmount PositiveDecimal (string)required

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    FormSessionID uuidrequired

    Unique identifier for the Form Session. Form Session allows ramping using provided form data.

    Nonce Nonce (string)required

    A string which must be unique each time a new transaction is created, like a UUID or operation sequence number. Request can be idempotently retried by using the same Nonce.

    Possible values: non-empty and <= 36 characters

    Example: dc879b38-494b-4de7-98a9-068703144328
    ExternalID ExternalID (string)

    Unique identifier in user's system.

    Possible values: non-empty and <= 36 characters

Responses

Sell request successful
Schema
    Transactionobjectrequired
    ID uuidrequired
    PublicID string
    Network Network (string)required

    Payments network:

    • Bitcoin
    • Lightning
    • Ethereum
    • PolygonPos
    • OffNetwork
    Example: Bitcoin
    Created date-timerequired

    When was this transaction created

    Example: 2024-04-16T08:00:55Z
    Status TransactionStatus (string)required

    Statuses for transactions.

    Possible values: [Pending, Failed, Settled]

    Example: Settled
    Direction TransactionDirection (string)required

    Whether the transactions was a credit (in) or a debit (out) in your account

    Possible values: [In, Out]

    Example: In
    CustomerID CustomerID (string)

    A unique ID which identifies the customer in the Business' internal system and in NOAH.

    Possible values: non-empty and <= 36 characters

    Example: 550e8400-e29b-41d4-a716-446655440000
    ExternalID ExternalID (string)

    Unique identifier in user's system.

    Possible values: non-empty and <= 36 characters

    Amount PositiveDecimal (string)

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    NetworkFee PositiveDecimal (string)

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    CryptoCurrency CryptoCurrencyCode (string)required

    Cryptocurrency code:

    • BTC
    • USDC
    Example: BTC

    FiatPayment

    object
    • For buy transactions, Transaction.Amount = (FiatPayment.Amount - FiatPayment.FeeAmount) / FiatPayment.Rate
    • For sell transactions, Transaction.Amount = (FiatPayment.Amount + FiatPayment.FeeAmount) / FiatPayment.Rate
    Amount PositiveDecimal (string)required

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    FeeAmount PositiveDecimal (string)required

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    Rate PositiveDecimal (string)

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    FiatCurrency FiatCurrencyCode (string)required

    Supported fiat ISO_4217 3 letter currency codes.

    Example: USD

    Orchestration

    object

    Orchestration details for the transaction.

    RuleID stringrequired

    Unique identifier for the rule that is matched for the transaction.

    RuleExecutionID stringrequired

    Unique identifier for the execution of the rules that is matched for the transaction.

Callbacks

POST 

/

Send a callback to the specified URL when the payment status updates.

Body

required
    EventType stringrequired

    Type of the event being sent:

    • Transaction
    • FiatDeposit
    EventVersion integerrequired

    Version of the event

    Example: 0
    Occurred date-timerequired

    Time the event occurred

    Example: 2024-04-16T08:00:55Z
    Dataobjectrequired

    Data specific to the event.

    oneOf

    ID uuidrequired
    PublicID string
    Network Network (string)required

    Payments network:

    • Bitcoin
    • Lightning
    • Ethereum
    • PolygonPos
    • OffNetwork
    Example: Bitcoin
    Created date-timerequired

    When was this transaction created

    Example: 2024-04-16T08:00:55Z
    Status TransactionStatus (string)required

    Statuses for transactions.

    Possible values: [Pending, Failed, Settled]

    Example: Settled
    Direction TransactionDirection (string)required

    Whether the transactions was a credit (in) or a debit (out) in your account

    Possible values: [In, Out]

    Example: In
    CustomerID CustomerID (string)

    A unique ID which identifies the customer in the Business' internal system and in NOAH.

    Possible values: non-empty and <= 36 characters

    Example: 550e8400-e29b-41d4-a716-446655440000
    ExternalID ExternalID (string)

    Unique identifier in user's system.

    Possible values: non-empty and <= 36 characters

    Amount PositiveDecimal (string)

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    NetworkFee PositiveDecimal (string)

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    CryptoCurrency CryptoCurrencyCode (string)required

    Cryptocurrency code:

    • BTC
    • USDC
    Example: BTC

    FiatPayment

    object
    • For buy transactions, `Transaction.Amount = (FiatPayment.Amount
    • FiatPayment.FeeAmount) / FiatPayment.Rate* For sell transactions,Transaction.Amount = (FiatPayment.Amount + FiatPayment.FeeAmount) / FiatPayment.Rate`
    Amount PositiveDecimal (string)required

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    FeeAmount PositiveDecimal (string)required

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    Rate PositiveDecimal (string)

    Positive decimal number in string format

    Possible values: non-empty and <= 38 characters, Value must match regular expression ^[+]?([.]\d+|\d+[.]?\d*)$

    Example: 10.1
    FiatCurrency FiatCurrencyCode (string)required

    Supported fiat ISO_4217 3 letter currency codes.

    Example: USD

    Orchestration

    object

    Orchestration details for the transaction.

    RuleID stringrequired

    Unique identifier for the rule that is matched for the transaction.

    RuleExecutionID stringrequired

    Unique identifier for the execution of the rules that is matched for the transaction.

    UserID stringrequired

    User ID of the event.

Callbacks Responses

Callback received successfully
Loading...