Pular para o conteúdo

Requisição

Updates an existing fee.

Segurança
Bearer
Caminho
idstring, (uuid)obrigatório

Provide the feeId of the fee you want to update.

Corpoapplication/jsonobrigatório
valuenumberobrigatório

Value of the fee to apply.

Set the value of this parameter according to the fee type you are using:

fee_typeCorresponding value to use
PERCENTAGEvalue must be >0 and <100.
FLAT_RATEvalue can be negative.

Note: The final amount of the fee is applied either as a percentage or a flat rate depending on the value you specify for the fee_type parameter.

Exemplo:0.025
currency_codestringobrigatório

Currency the fee is applied in. Ripple recommends using ISO-4217 currency codes, although no formal constraint is enforced.

Exemplo:"USD"
role_typestringobrigatório

Role of the party to which the fee applies.

Enum ValueDescription
SENDING

Charge the originator of the payment.

RECEIVING

Charge the beneficiary of the payment.

INSTITUTION_SENDING

Charge the financial institution sending the payment.

INSTITUTION_RECEIVING

Charge the financial institution receiving the payment.

Exemplo:"SENDING"
payment_typestringobrigatório

Type of payment to which the fee applies.

Enum ValueDescription
REGULAR

Apply the fee to a regular payment.

RETURN

Apply the fee to a return payment.

Exemplo:"REGULAR"
node_typestringobrigatório

Fiat instance to which the fee applies.

Enum ValueDescription
INITIAL

Apply the fee to the first fiat instance in the payment chain.

INTERMEDIATE

Apply the fee to each fiat instance in the payment chain that is not the first or last.

TERMINAL

Apply the fee to the last fiat instance in the payment chain.

Exemplo:"INITIAL"
fee_typestringobrigatório

Type of fee to apply. This is used with fee value to calculate the fee.

Enum ValueDescription
PERCENTAGE

Apply the fee value as a percentage.

FLAT_RATE

Apply the fee value as a flat rate.

Exemplo:"FLAT_RATE"
partner_namestring

Owner of the account involved in the payment, in RippleNet Address format. For example, rn.us.ca.san_francisco.

Exemplo:"rn.us.ca.san_francisco"
account_namestring

Account to apply the fee to. Specify the account name. For example, conct_usd_sf. If specified, you must also specify a partner_name value.

Exemplo:"conct_usd_sf"
upper_limitnumber

Maximum amount for the range of a slab-based fee. If specified, you must also specify a lower_limit value.

Exemplo:1000
lower_limitnumber

Minimum amount for the range of a slab-based fee. If specified, you must also specify an upper_limit value.

Exemplo:0
payout_methodstring

The payout method by which the receiving institution delivers the funds to the end customer.

Exemplo:"LOCAL_RAILS"
fee_categorystring

Category that describes the purpose of the fee.

Padrão:"NONE"
Enum ValueDescription
NONE

None

OVERSEAS_DELIVERY_CHARGES

Overseas delivery charges.

BENEFICIARY_BANK_CHARGE

Charge from beneficiary bank.

PROCESSING_HANDLING_CHARGE

Processing and handling charge.

LOCAL_GOVERNMENT_CHARGE

Local government charge.

OTHER

Other charges.

Exemplo:"BENEFICIARY_BANK_CHARGE"
fee_descriptionstring

Optional free-form description for the fee.

curl -i -X PUT \
  'https://docs.ripple.com/_mock/pt-br/products/payments-odl/api-docs/ripplenet/reference/openapi/config/fees/{id}' \
  -H 'Authorization: YOUR_API_KEY_HERE' \
  -H 'Content-Type: application/json' \
  -d '{
    "value": 0.025,
    "currency_code": "USD",
    "role_type": "SENDING",
    "payment_type": "REGULAR",
    "node_type": "INITIAL",
    "fee_type": "FLAT_RATE",
    "partner_name": "rn.us.ca.san_francisco",
    "account_name": "conct_usd_sf",
    "upper_limit": 1000,
    "lower_limit": 0,
    "payout_method": "LOCAL_RAILS",
    "fee_category": "BENEFICIARY_BANK_CHARGE",
    "fee_description": "string"
  }'

Respostas

Successfully updated fee.

Corpoapplication/json
valuenumberobrigatório

Value of the fee to be applied. fiat node uses this value and fee_type to calculate the fee.

Exemplo:2
currency_codestringobrigatório

Currency this fee applies to.

Exemplo:"USD"
role_typestringobrigatório

Role of the party to which the fee applies.

If set to SENDING, the fee is charged to the originator of the payment.

If set to RECEIVING, the fee is charged to the beneficiary of the payment.

If set to INSTITUTION_SENDING, the fee is charged to the financial institution that is sending the payment.

If set to INSTITUTION_RECEIVING, the fee is charged to the financial institution that is receiving the payment.

Enum:"SENDING""RECEIVING""INSTITUTION_SENDING""INSTITUTION_RECEIVING"
Exemplo:"SENDING"
payment_typestringobrigatório

Payment type the fee applies to.

Enum:"REGULAR""RETURN"
Exemplo:"REGULAR"
node_typestringobrigatório

Fiat node to which the fee applies.

If set to INITIAL, the fee is charged to the first fiat instance in the payment chain.

If set to INTERMEDIATE, the fee is charged to each fiat instance in the payment chain that is not the first or last fiat instance.

If set to TERMINAL, the fee is charged to the last fiat instance in the payment chain.

Enum:"INITIAL""INTERMEDIATE""TERMINAL"
Exemplo:"INITIAL"
fee_typestringobrigatório

Method used to calculate the fee.

Enum:"PERCENTAGE""FLAT_RATE"
Exemplo:"FLAT_RATE"
partner_namestring

Owner of the account involved in the payment, in RippleNet Address format. For example, rn.us.ca.san_francisco.

Exemplo:"rn.us.ca.san_francisco"
account_namestring

For a fee that applies to a specific account, provides the account name. Used in combination with the partner_name value.

Exemplo:"conct_usd_sf"
upper_limitnumber

For a slab-based fee, provides the upper limit of the slab. Used in combination with the lower_limit value.

Exemplo:1000
lower_limitnumber

For a slab-based fee, provides the lower limit of the slab. Used in combination wtih the upper_limit value.

Exemplo:0
feeIdstring, (uuid)obrigatório

Unique identifier of the fee.

Exemplo:"7740f31c-ca03-4414-b491-b285aef71eb1"
payout_methodstring

The payout method for this fee.

Exemplo:"LOCAL_RAILS"
fee_categorystring

Category that describes the purpose of the fee.

Padrão:"NONE"
Enum:"NONE""OVERSEAS_DELIVERY_CHARGES""BENEFICIARY_BANK_CHARGE""PROCESSING_HANDLING_CHARGE""LOCAL_GOVERNMENT_CHARGE""OTHER"
Exemplo:"BENEFICIARY_BANK_CHARGE"
fee_descriptionstring

Optional free-form description for the fee.

Resposta
{ "value": 2, "currency_code": "USD", "role_type": "SENDING", "payment_type": "REGULAR", "node_type": "INITIAL", "fee_type": "FLAT_RATE", "partner_name": "rn.us.ca.san_francisco", "account_name": "conct_usd_sf", "upper_limit": 1000, "lower_limit": 0, "feeId": "7740f31c-ca03-4414-b491-b285aef71eb1", "payout_method": "LOCAL_RAILS", "fee_category": "BENEFICIARY_BANK_CHARGE", "fee_description": "string" }