CryptoOnrampSessions
Create and retrieve Crypto Onramp Sessions.
Table Specific Information
Select
Server-Side Query Support
The 本製品 uses the Stripe API to filter the results by the following columns and operators while the rest of the filter is executed client-side within the 本製品.
- Id, Status, TransactionDetailsDestinationCurrency, TransactionDetailsDestinationNetwork support the following operator: =.
- Created supports the following operators: <, >, >=, <, <=, =.
You can select:
A Crypto Onramp Session by specifying its Id:
SELECT * FROM CryptoOnrampSessions WHERE Id = 'cos_1NamBL2eZvKYlo2CP38sZVEW';
A Crypto Onramp Session created after a specific date (Created may be used with the >, >=, <, <=, or = conditions and may be used twice to specify a range):
SELECT * FROM CryptoOnrampSessions WHERE Created = '2023-07-21 19:00:27.0'
A Crypto Onramp Session by specifying its Status:
SELECT * FROM CryptoOnrampSessions WHERE Status = 'initialized';
A Crypto Onramp Session by specifying its TransactionDetailsDestinationCurrency:
SELECT * FROM CryptoOnrampSessions WHERE TransactionDetailsDestinationCurrency = 'USD'
A Crypto Onramp Session by specifying its TransactionDetailsDestinationNetwork:
SELECT * FROM CryptoOnrampSessions WHERE TransactionDetailsDestinationNetwork = 'ethereum'
Insert
The columns that are not read-only can be inserted.Example
INSERT INTO CryptoOnrampSessions (TransactionDetailsWalletAddressesEthereum) VALUES ('0xB00F0759DbeeF5E543Cc3E3B07A6442F5f3928a2')
Columns
| Name | Type | ReadOnly | References | Description |
| Id [KEY] | String | True |
Unique identifier for the Crypto Onramp Session object. | |
| ClientSecret | String | True |
A client secret that can be used to drive a single session using our embedded widget. | |
| Created | Datetime | True |
Time at which the object was created. Measured in seconds since the Unix epoch. | |
| KycDetailsProvided | Boolean | True |
Has the value true if any user kyc details were provided during the creation of the onramp session. Otherwise, has the value false. | |
| Livemode | Boolean | True |
Has the value true if the object exists in live mode or the value false if the object exists in test mode. | |
| MetadataAggregate | String | False |
Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to metadata. | |
| RedirectUrl | String | True |
Redirect your users to the URL for a prebuilt frontend integration of the crypto onramp on the standalone hosted onramp. | |
| Status | String | True |
The status of the Onramp Session. One of = {initialized, rejected, requires_payment, fulfillment_processing, fulfillment_complete}. | |
| Object | String | True |
String representing the object's type. Objects of the same type share the same value. | |
| TransactionDetailsDestinationAmount | String | False |
The amount of crypto the customer will get deposited into their wallet. When left null, a default value is computed if source_amount, destination_currency, and destination_network are set. When set, both destination_currency and destination_network must also be set. All cryptocurrencies are supported to their full precisions (for example, 18 decimal places for eth). We validate and generate an error if the amount exceeds the supported precision based on the exchange currency. Setting source_amount is mutually exclusive with setting destination_amount (only one or the other is supported). | |
| TransactionDetailsDestinationCurrencies | String | False |
If a platform wants to lock the currencies a session will support, they can add supported currencies to this array. If left null, the experience will allow selection of all supported destination currencies and all supported cryptocurrencies are shown in the onramp UI subject to destination_networks if set. When set, it must be a non-empty array where all values in the array are valid cryptocurrencies. You can use it to lock users to a specific cryptocurrency by passing a single value array. Users cannot override this parameter. | |
| TransactionDetailsDestinationCurrency | String | False |
The selected destination_currency to convert the source to. This should be a crypto currency code. If supported_destination_currencies is set, it must be a value in that array. When left null, the first value of destination_currencies is selected. When set, if destination_currencies is also set, the value of destination_currency must be present in that array. To lock a destination_currency, specify that value as the single value for destination_currencies. Users can select a different cryptocurrency in the onramp UI subject to destination_currencies if set. | |
| TransactionDetailsDestinationNetwork | String | False |
The specific crypto network the destination_currency is settled on. If supported_destination_networks is set, it must be a value in that array. When left null, the first value of destination_networks is selected. When set, if destination_networks is also set, the value of destination_network must be present in that array. To lock a destination_network, specify that value as the single value for destination_networks. Users can select a different network in the onramp UI subject to destination_networks if set. | |
| TransactionDetailsDestinationNetworks | String | False |
If a platform wants to lock the supported networks, they can do so through this array. If left null, the experience will allow selection of all supported networks. When set, it must be a non-empty array where values in the array are each a valid crypto network. It can be used to lock users to a specific network by passing a single value array. Users cannot override this parameter. | |
| TransactionDetailsFeesNetworkFeeAmount | String | True |
The cost associated with moving crypto from Stripe to the end consumer's wallet. e.g: for ETH, this is called 'gas fee', for BTC this is a 'miner's fee'. | |
| TransactionDetailsFeesTransactionFeeAmount | String | True |
Fee for processing the transaction. | |
| TransactionDetailsLockWalletAddress | Boolean | False |
Whether to lock the suggested wallet address. If destination tags are provided, this will also lock the destination tags. | |
| TransactionDetailsSourceAmount | String | False |
The amount of fiat we intend to onramp - excluding fees. When left null, a default value is computed if destination_amount is set. When set, setting source_amount is mutually exclusive with setting destination_amount (only one or the other is supported). We don’t support fractional pennies. If fractional minor units of a currency are passed in, it generates an error. Users can update the value in the onramp UI. | |
| TransactionDetailsSourceCurrency | String | False |
A fiat currency code. When left null, a default currency is selected based on user locale. When set, it must be one of the fiat currencies supported by onramp. Users can still select a different currency in the onramp UI. | |
| TransactionDetailsTransactionId | String | True |
The transaction id of the transaction that was sent to the customer's wallet. This will only be set if the sessions hits the status=fulfillment_complete and we've transferred the crypto successfully to the external wallet. e.g: https://etherscan.io/tx/0xc2573af6b3a18e6f7c0e1cccc187a483f61d72cbb421f7166970d3ab45731a95. | |
| TransactionDetailsWalletAddress | String | True |
The consumer's wallet address (where crypto will be sent to). | |
| TransactionDetailsWalletAddressesBaseNetwork | String | False |
The end customer's crypto wallet base address (for each network) to use for this transaction. | |
| TransactionDetailsWalletAddressesBitcoin | String | False |
The end customer's crypto wallet bitcoin address (for each network) to use for this transaction. | |
| TransactionDetailsWalletAddressesDestinationTagsStellar | String | False |
The end customer's crypto wallet stellar destination tag (for each network) to use for this transaction. | |
| TransactionDetailsWalletAddressesEthereum | String | False |
The end customer's crypto wallet ethereum address (for each network) to use for this transaction. | |
| TransactionDetailsWalletAddressesOptimism | String | False |
The end customer's crypto wallet optimism address (for each network) to use for this transaction. | |
| TransactionDetailsWalletAddressesPolygon | String | False |
The end customer's crypto wallet polygon address (for each network) to use for this transaction. | |
| TransactionDetailsWalletAddressesSolana | String | False |
The end customer's crypto wallet solana address (for each network) to use for this transaction. | |
| TransactionDetailsWalletAddressesStellar | String | False |
The end customer's crypto wallet stellar address (for each network) to use for this transaction. |
Pseudo-Columns
SELECT ステートメントのWHERE 句では、疑似カラムフィールドを使用して、データソースから返されるタプルを詳細に制御することができます。
| Name | Type | Description |
| CustomerIpAddress | String |
The IP address of the customer the platform intends to onramp. If the user’s IP is in a region Stripe can’t support, Stripe returns an HTTP 400 with an appropriate error code. |
| KycDetails | String |
Pre-populate some of the required KYC information for the user if you’ve already collected it within your application. |