> For the complete documentation index, see [llms.txt](https://docs.intents.aurora.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.intents.aurora.dev/intents-deposits/api-reference/submit-a-deposit.md).

# Submit a deposit

## POST /api/deposit/submit/{apiKey}

> Optionally notify the 1Click service that a deposit has been sent to the deposit address, using the blockchain transaction hash. This can speed up swap processing by allowing the system to preemptively verify the deposit. This endpoint is a transparent proxy to the 1Click API.

```json
{"openapi":"3.0.3","info":{"title":"@aurora-is-near/intents-fee-service","version":"0.0.1"},"servers":[{"url":"https://intents-api.aurora.dev"}],"security":[],"paths":{"/api/deposit/submit/{apiKey}":{"post":{"tags":["deposit"],"description":"Optionally notify the 1Click service that a deposit has been sent to the deposit address, using the blockchain transaction hash. This can speed up swap processing by allowing the system to preemptively verify the deposit. This endpoint is a transparent proxy to the 1Click API.","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"txHash":{"type":"string","description":"Transaction hash of your deposit."},"depositAddress":{"type":"string","description":"Deposit address returned in the quote response."},"nearSenderAccount":{"description":"Sender account (used only for the NEAR blockchain).","type":"string"},"memo":{"description":"Memo. Use if the deposit was submitted with one.","type":"string"}},"required":["txHash","depositAddress"]}}},"required":true},"parameters":[{"schema":{"type":"string"},"in":"path","name":"apiKey","required":true,"description":"API key generated at [https://studio.aurora.dev](https://studio.aurora.dev)"}],"responses":{"200":{"description":"Deposit transaction submitted successfully","content":{"application/json":{"schema":{"type":"object","properties":{"correlationId":{"type":"string","description":"Unique identifier for request tracing and debugging."},"quoteResponse":{"type":"object","properties":{"timestamp":{"type":"string","description":"Timestamp in ISO format used to derive the deposit address for this quote."},"signature":{"type":"string","description":"1Click service signature confirming the quote for the specific deposit address."},"correlationId":{"type":"string","description":"Unique identifier for request tracing and debugging."},"quoteRequest":{"type":"object","properties":{"dry":{"type":"boolean","description":"Flag indicating whether this is a dry run request.\n\nIf `true`, the response will NOT contain the following fields:\n\n- `depositAddress`\n\n- `timeWhenInactive`\n\n- `deadline`"},"swapType":{"type":"string","enum":["EXACT_INPUT","EXACT_OUTPUT","FLEX_INPUT","ANY_INPUT"],"description":"How to interpret `amount` (and refunds) when performing the swap:\n\n- `EXACT_INPUT` — requests the output amount for an exact input.\n\n  - If deposit is less than `amountIn`, the deposit is refunded by deadline.\n\n  - If deposit is above than `amountIn`, the swap is processed and the excess is refunded to refundTo address after swap is complete.\n\n- `EXACT_OUTPUT` — requests the input amount for an exact output.\n\n  - The quote response includes `minAmountIn` and `maxAmountIn`.\n\n  - If the input is above `maxAmountIn`, the swap is processed and the excess is refunded to `refundTo` after the swap is complete.\n\n  - If the input is below `minAmountIn`, the deposit is refunded by deadline.\n\n- `FLEX_INPUT` — a flexible input amount that allows for partial deposits and variable amounts.\n\n  - `slippage` applies both to `amountOut` and `amountIn` and defines an acceptable range (`minAmountIn` and `minAmountOut`).\n\n  - Any amount higher than `minAmountIn` is accepted and converted to the output asset as long as `minAmountOut` is met.\n\n  - `amountIn` can be less, as long as the 'slippage + 1%' constraint is met. If the total received by the deadline is below the lower bound, the deposit is refunded.\n\n  - If deposits exceed the upper bound, the swap is still processed."},"depositType":{"type":"string","enum":["ORIGIN_CHAIN","INTENTS"],"description":"Type of deposit address:\n\n- `ORIGIN_CHAIN` - deposit address on the origin chain.\n\n- `INTENTS` - the account ID within NEAR Intents to which you should transfer assets."},"depositMode":{"description":"What deposit address mode you will get in the response.\n\nMost chains support only `SIMPLE`, and some (for example `stellar`) only `MEMO`:\n\n- `SIMPLE` - usual deposit with only a deposit address.\n\n- `MEMO` - some chains require the `memo` together with `depositAddress` for the swap to work.","type":"string","enum":["SIMPLE","MEMO"]},"quoteWaitingTimeMs":{"description":"Time in milliseconds the user is willing to wait for a quote from the relay.\n\nUse `0` to request the fastest available quote.","type":"number"},"sessionId":{"description":"Unique client session identifier.","type":"string"},"amount":{"type":"string","description":"Amount to swap as the base amount, in the smallest unit of the currency. It is interpreted as input or output based on `swapType`."},"originAsset":{"type":"string","description":"ID of the origin asset."},"destinationAsset":{"type":"string","description":"ID of the destination asset."},"slippageTolerance":{"type":"number","description":"Slippage tolerance for the swap in basis points (1/100th of a percent), e.g. 100 for 1%."},"refundTo":{"type":"string","description":"Address used for refunds."},"refundType":{"type":"string","enum":["ORIGIN_CHAIN","INTENTS"],"description":"Type of refund address:\n\n- `ORIGIN_CHAIN` - assets are refunded to the `refundTo` address on the origin chain.\n\n- `INTENTS` - assets are refunded to the `refundTo` Intents account."},"recipient":{"type":"string","description":"Recipient address. The format must match `recipientType`."},"recipientType":{"type":"string","enum":["DESTINATION_CHAIN","INTENTS"],"description":"Type of recipient address:\n\n- `DESTINATION_CHAIN` - assets are transferred to the chain of `destinationAsset`.\n\n- `INTENTS` - assets are transferred to an account inside Intents."},"virtualChainRecipient":{"description":"EVM address of a transfer recipient in a virtual chain.","type":"string"},"virtualChainRefundRecipient":{"description":"EVM address of a refund recipient in a virtual chain.","type":"string"},"deadline":{"type":"string","description":"Timestamp in ISO format indicating when refunds begin if the swap is not completed by then."},"connectedWallets":{"description":"Addresses of connected wallets.","type":"array","items":{"type":"string"}},"referral":{"description":"Referral identifier (lowercase only). It is reflected in on-chain data and public analytics platforms.","type":"string"},"appFees":{"description":"List of recipients and their fees.","type":"array","items":{"type":"object","properties":{"recipient":{"type":"string","description":"Fee recipient identifier or address."},"fee":{"type":"number","description":"Fee amount in basis points (1/100th of a percent)."}},"required":["recipient","fee"],"additionalProperties":false}},"customRecipientMsg":{"description":"HIGHLY EXPERIMENTAL: message to pass to `ft_transfer_call` when withdrawing assets to NEAR.\n\nOtherwise, `ft_transfer` will be used.\n\nWARNING: Funds can be lost if used with non NEP-141 tokens, with insufficient `storage_deposit`, or if the recipient does not implement `ft_on_transfer`.","type":"string"}},"required":["dry","swapType","depositType","amount","originAsset","destinationAsset","slippageTolerance","refundTo","refundType","recipient","recipientType","deadline"],"additionalProperties":false,"description":"User request payload."},"quote":{"type":"object","properties":{"timeEstimate":{"type":"number","description":"Estimated swap completion time in seconds."},"deadline":{"description":"Timestamp in ISO format indicating when the quote becomes inactive and refunds may begin.","type":"string"},"timeWhenInactive":{"description":"Timestamp in ISO format indicating when the deposit address becomes inactive.","type":"string"},"depositAddress":{"description":"Unique deposit address to which the origin asset must be transferred to initiate the swap.","type":"string"},"depositMemo":{"description":"Additional memo required together with `depositAddress` for memo-based deposit chains.","type":"string"},"amountIn":{"type":"string","description":"Input amount in the smallest unit of the origin asset."},"amountInFormatted":{"type":"string","description":"Human-readable formatted input amount."},"amountInUsd":{"type":"string","description":"Estimated USD value of the input amount."},"minAmountIn":{"type":"string","description":"Minimum accepted input amount for the quote."},"maxAmountIn":{"description":"Maximum accepted input amount for the quote, when applicable.","type":"string"},"amountOut":{"type":"string","description":"Expected output amount in the smallest unit of the destination asset."},"amountOutFormatted":{"type":"string","description":"Human-readable formatted output amount."},"amountOutUsd":{"type":"string","description":"Estimated USD value of the output amount."},"minAmountOut":{"type":"string","description":"Minimum guaranteed output amount for the quote."},"virtualChainRecipient":{"description":"EVM address of a transfer recipient in a virtual chain.","type":"string"},"virtualChainRefundRecipient":{"description":"EVM address of a refund recipient in a virtual chain.","type":"string"},"customRecipientMsg":{"description":"HIGHLY EXPERIMENTAL: message passed to `ft_transfer_call` when withdrawing assets to NEAR. Otherwise, `ft_transfer` is used.","type":"string"}},"required":["timeEstimate","amountIn","amountInFormatted","amountInUsd","minAmountIn","amountOut","amountOutFormatted","amountOutUsd","minAmountOut"],"additionalProperties":false,"description":"Quote details, including deposit instructions and expected swap amounts."}},"required":["timestamp","signature","correlationId","quoteRequest","quote"],"additionalProperties":false,"description":"Quote response from the original request."},"status":{"type":"string","enum":["KNOWN_DEPOSIT_TX","PENDING_DEPOSIT","INCOMPLETE_DEPOSIT","PROCESSING","SUCCESS","REFUNDED","FAILED"],"description":"Current execution status of the swap:\n\n- `KNOWN_DEPOSIT_TX` - a deposit transaction is known but not yet confirmed.\n\n- `PENDING_DEPOSIT` - waiting for the deposit to arrive at the deposit address.\n\n- `INCOMPLETE_DEPOSIT` - the deposit received is below the required amount.\n\n- `PROCESSING` - the deposit was received and the swap is being processed.\n\n- `SUCCESS` - the swap completed successfully.\n\n- `REFUNDED` - the deposit was refunded.\n\n- `FAILED` - the swap failed."},"updatedAt":{"type":"string","description":"Timestamp in ISO format when the state was last updated."},"swapDetails":{"type":"object","properties":{"intentHashes":{"type":"array","items":{"type":"string"},"description":"All intent hashes that took part in this swap."},"nearTxHashes":{"type":"array","items":{"type":"string"},"description":"All NEAR transactions executed for this swap."},"amountIn":{"description":"Exact amount of `originToken` after the trade was settled.","type":"string"},"amountInFormatted":{"description":"Exact amount of `originToken` in readable format after the trade was settled.","type":"string"},"amountInUsd":{"description":"Exact amount of `originToken` equivalent in USD.","type":"string"},"amountOut":{"description":"Exact amount of `destinationToken` after the trade was settled.","type":"string"},"amountOutFormatted":{"description":"Exact amount of `destinationToken` in readable format after the trade was settled.","type":"string"},"amountOutUsd":{"description":"Exact amount of `destinationToken` equivalent in USD.","type":"string"},"slippage":{"description":"Actual slippage.","type":"number"},"originChainTxHashes":{"type":"array","items":{"type":"object","properties":{"hash":{"type":"string","description":"Transaction hash."},"explorerUrl":{"type":"string","description":"Explorer URL for the transaction."}},"required":["hash","explorerUrl"],"additionalProperties":false},"description":"Hashes and explorer URLs for all transactions on the origin chain."},"destinationChainTxHashes":{"type":"array","items":{"type":"object","properties":{"hash":{"type":"string","description":"Transaction hash."},"explorerUrl":{"type":"string","description":"Explorer URL for the transaction."}},"required":["hash","explorerUrl"],"additionalProperties":false},"description":"Hashes and explorer URLs for all transactions on the destination chain."},"refundedAmount":{"description":"Amount of `originAsset` transferred to `refundTo`.","type":"string"},"refundedAmountFormatted":{"description":"Refunded amount in readable format.","type":"string"},"refundedAmountUsd":{"description":"Refunded amount equivalent in USD.","type":"string"},"refundReason":{"description":"Reason for refund.","type":"string"},"depositedAmount":{"description":"Amount deposited to `depositAddress` onchain.","type":"string"},"depositedAmountFormatted":{"description":"Amount deposited in readable format.","type":"string"},"depositedAmountUsd":{"description":"Amount deposited equivalent in USD.","type":"string"},"referral":{"description":"Referral identifier.","type":"string"}},"required":["intentHashes","nearTxHashes","originChainTxHashes","destinationChainTxHashes"],"additionalProperties":false,"description":"Details of actual swaps and withdrawals."}},"required":["correlationId","quoteResponse","status","updatedAt","swapDetails"],"additionalProperties":false,"description":"Deposit transaction submitted successfully"}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"anyOf":[{"type":"object","properties":{"message":{"type":"string","description":"Error message returned by the upstream quote API."},"correlationId":{"type":"string","description":"Unique identifier for request tracing and debugging."},"timestamp":{"type":"string","description":"Timestamp in ISO format when the error response was generated."},"path":{"type":"string","description":"API path associated with the failed request."}},"required":["message","correlationId","timestamp","path"],"additionalProperties":false,"description":"API error or invalid request parameters"},{"type":"object","properties":{"message":{"type":"string"},"error":{"type":"string"},"data":{"type":"object","additionalProperties":{}},"statusCode":{"type":"number"}},"required":["message","statusCode"],"additionalProperties":false}]}}}},"500":{"description":"Internal Server Error - Failed to reach the deposit service","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"error":{"type":"string"},"data":{"type":"object","additionalProperties":{}},"statusCode":{"type":"number","enum":[500]}},"required":["message","statusCode"],"additionalProperties":false,"description":"Internal Server Error - Failed to reach the deposit service"}}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.intents.aurora.dev/intents-deposits/api-reference/submit-a-deposit.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
