get-transfers-WTID.rst (3144B)
1 .. http:get:: /transfers/$WTID 2 3 Provides deposits associated with a given wire transfer. The 4 wire transfer identifier (WTID) and the base URL for tracking 5 the wire transfer are both given in the wire transfer subject. 6 7 **Response:** 8 9 :http:statuscode:`200 OK`: 10 The wire transfer is known to the exchange, details about it follow in the body. 11 The body of the response is a `TrackTransferResponse`. 12 :http:statuscode:`400 Bad Request`: 13 The ``$WTID`` is malformed. 14 This response comes with a standard `ErrorDetail` response with 15 a code of ``TALER_EC_EXCHANGE_TRANSFERS_GET_WTID_MALFORMED``. 16 :http:statuscode:`404 Not found`: 17 The wire transfer identifier is unknown to the exchange. 18 Returned with an error code of 19 ``TALER_EC_EXCHANGE_TRANSFERS_GET_WTID_NOT_FOUND``. 20 :http:statuscode:`500 Internal server error`: 21 The exchange encountered an internal problem processing 22 the request. Error codes used are: 23 - ``TALER_EC_GENERIC_DB_FETCH_FAILED`` 24 - ``TALER_EC_GENERIC_DB_INVARIANT_FAILURE`` 25 - ``TALER_EC_GENERIC_JSON_ALLOCATION_FAILURE`` 26 - ``TALER_EC_EXCHANGE_TRANSFERS_GET_WIRE_FEE_NOT_FOUND`` 27 - ``TALER_EC_EXCHANGE_TRANSFERS_GET_WIRE_FEE_INCONSISTENT`` 28 29 .. ts:def:: TrackTransferResponse 30 31 interface TrackTransferResponse { 32 // Actual amount of the wire transfer, excluding the wire fee. 33 total: Amount; 34 35 // Applicable wire fee that was charged. 36 wire_fee: Amount; 37 38 // Public key of the merchant (identical for all deposits). 39 merchant_pub: EddsaPublicKey; 40 41 // Hash of the payto:// account URI (identical for all deposits). 42 h_payto: FullPaytoHash; 43 44 // Time of the execution of the wire transfer by the exchange. 45 execution_time: Timestamp; 46 47 // Details about the deposits. 48 deposits: TrackTransferDetail[]; 49 50 // Signature from the exchange made with purpose 51 // ``TALER_SIGNATURE_EXCHANGE_CONFIRM_WIRE_DEPOSIT`` 52 // over a `TALER_WireDepositDataPS`. 53 exchange_sig: EddsaSignature; 54 55 // Public EdDSA key of the exchange that was used to generate the signature. 56 // Should match one of the exchange's signing keys from ``/keys``. Again given 57 // explicitly as the client might otherwise be confused by clock skew as to 58 // which signing key was used. 59 exchange_pub: EddsaPublicKey; 60 } 61 62 .. ts:def:: TrackTransferDetail 63 64 interface TrackTransferDetail { 65 // SHA-512 hash of the contact of the merchant with the customer. 66 h_contract_terms: HashCode; 67 68 // Coin's public key, both ECDHE and EdDSA. 69 coin_pub: CoinPublicKey; 70 71 // The total amount the original deposit was worth, 72 // including fees and after applicable refunds. 73 deposit_value: Amount; 74 75 // Applicable fees for the deposit, possibly 76 // reduced or waived due to refunds. 77 deposit_fee: Amount; 78 79 // Refunds that were applied to the value of 80 // this coin. Optional. 81 // @since protocol **v19**. Before, refunds were 82 // incorrectly still included in the 83 // ``deposit_value`` (!). 84 refund_total?: Amount; 85 86 }