Three lines

Uber

Developers

API Reference - Update Refund

Update refund

Update the refund using the callback endpoint.
The endpoint should be called only once, however in some cases it’s possible to update the refund state from SUCCEEDED to FAILED, for example if the user’s bank account is no longer valid.
FAILED is the terminal state and can’t be changed.

Make your request at this endpoint:

POST /v1/payments/refunds/:id

Authentication

OAuth 2.0 bearer token with the payments.deposits scope.

Retry strategy

On 5xx, Partner should retry the http call.

On 4xx, Partner should not retry.

Path Parameters

Name Type Description
id String Refund ID

Body parameters

Name Type Required Description
status String required SUCCEEDED or FAILED
merchant_reference String optional Refund reference id in Partner’s system. Allows to update previously set merchant_reference if needed.
failed_reason String optional Up to 256 characters

Example request and response

The following is an example request for the update refund resource. To use this request, replace $token in the example below with the access token.

curl -X POST \
  https://sandbox-api.uber.com/v1/payments/refunds/05f4aed6-5d98-43e1-a35b-52886cbdb42b \
  -H "Authorization: Bearer $token" \
  -H 'Content-Type: application/json' \
  -d '{
  "status": "FAILED",
  "merchant_reference": "e6bef50cfc344987a4d7",
  "failed_reason": "Bank account doesn't exist."
}'

This is an example of what you can expect to see in response:

Example Response: Status-code: 200 OK
Example Response Body: EMPTY

Update refund errors

HTTP Status Description
400 Bad request
401 Not authenticated
403 Forbidden
404 Not Found
409 Conflict
429 Rate limited
500 Uber server error

Uber

Developers
© 2023 Uber Technologies Inc.