fetch information on a deposit, fiat only, for crypto transactions use fetchLedger https://docs.cdp.coinbase.com/coinbase-app/transfer-apis/deposit-fiat :param str id: deposit id :param str [code]: unified currency code :param dict [params]: extra parameter
(self, id: str, code: Str = None, params={})
| 4246 | return self.parse_transaction(data) |
| 4247 | |
| 4248 | def fetch_deposit(self, id: str, code: Str = None, params={}): |
| 4249 | """ |
| 4250 | fetch information on a deposit, fiat only, for crypto transactions use fetchLedger |
| 4251 | |
| 4252 | https://docs.cdp.coinbase.com/coinbase-app/transfer-apis/deposit-fiat |
| 4253 | |
| 4254 | :param str id: deposit id |
| 4255 | :param str [code]: unified currency code |
| 4256 | :param dict [params]: extra parameters specific to the exchange API endpoint |
| 4257 | :param str [params.accountId]: the id of the account that the funds were deposited into |
| 4258 | :returns dict: a `transaction structure <https://docs.ccxt.com/?id=transaction-structure>` |
| 4259 | """ |
| 4260 | self.load_markets() |
| 4261 | accountId = self.safe_string_2(params, 'account_id', 'accountId') |
| 4262 | params = self.omit(params, ['account_id', 'accountId']) |
| 4263 | if accountId is None: |
| 4264 | if code is None: |
| 4265 | raise ArgumentsRequired(self.id + ' fetchDeposit() requires an account_id(or accountId) parameter OR a currency code argument') |
| 4266 | accountId = self.find_account_id(code, params) |
| 4267 | if accountId is None: |
| 4268 | raise ExchangeError(self.id + ' fetchDeposit() could not find account id for ' + code) |
| 4269 | request = { |
| 4270 | 'account_id': accountId, |
| 4271 | 'deposit_id': id, |
| 4272 | } |
| 4273 | response = self.v2PrivateGetAccountsAccountIdDepositsDepositId(self.extend(request, params)) |
| 4274 | # |
| 4275 | # { |
| 4276 | # "data": { |
| 4277 | # "id": "67e0eaec-07d7-54c4-a72c-2e92826897df", |
| 4278 | # "status": "completed", |
| 4279 | # "payment_method": { |
| 4280 | # "id": "83562370-3e5c-51db-87da-752af5ab9559", |
| 4281 | # "resource": "payment_method", |
| 4282 | # "resource_path": "/v2/payment-methods/83562370-3e5c-51db-87da-752af5ab9559" |
| 4283 | # }, |
| 4284 | # "transaction": { |
| 4285 | # "id": "441b9494-b3f0-5b98-b9b0-4d82c21c252a", |
| 4286 | # "resource": "transaction", |
| 4287 | # "resource_path": "/v2/accounts/2bbf394c-193b-5b2a-9155-3b4732659ede/transactions/441b9494-b3f0-5b98-b9b0-4d82c21c252a" |
| 4288 | # }, |
| 4289 | # "amount": { |
| 4290 | # "amount": "10.00", |
| 4291 | # "currency": "USD" |
| 4292 | # }, |
| 4293 | # "subtotal": { |
| 4294 | # "amount": "10.00", |
| 4295 | # "currency": "USD" |
| 4296 | # }, |
| 4297 | # "created_at": "2015-01-31T20:49:02Z", |
| 4298 | # "updated_at": "2015-02-11T16:54:02-08:00", |
| 4299 | # "resource": "deposit", |
| 4300 | # "resource_path": "/v2/accounts/2bbf394c-193b-5b2a-9155-3b4732659ede/deposits/67e0eaec-07d7-54c4-a72c-2e92826897df", |
| 4301 | # "committed": True, |
| 4302 | # "fee": { |
| 4303 | # "amount": "0.00", |
| 4304 | # "currency": "USD" |
| 4305 | # }, |
nothing calls this directly
no test coverage detected