Alluvial
  • πŸš€Who is Alluvial?
  • πŸ—ΊοΈGuides
    • Mint and Redeem support
    • Secondary Interaction support
    • Reporting
    • Supplemental Guides
      • Architecture
      • Authentication
      • Redemptions
      • Staking
  • πŸ“–APIs
    • Authentication API
    • Ethereum Data API
    • Allowlisting API
    • Redemption API
    • Reporting API
    • Discounting API
    • Public APIs
  • 🌎Third Party Integration Guides
    • Fireblocks
  • Changelog
Powered by GitBook
On this page

Was this helpful?

Export as PDF
  1. APIs

Discounting API

PreviousReporting APINextPublic APIs

Last updated 7 months ago

Was this helpful?

APIs that allow Platforms to create target discount schedules.

πŸ“–
  • POSTCreate a discounted fee rate for an account
  • GETGet the discounted fee rate for an account
  • PATCHUpdate a discounted fee rate for an account

Get the discounted fee rate for an account

get

Get the discounted fee rate for an account

Authorizations
Path parameters
idOrKeystringRequired

Account ID or Key of the account to get discount rate for

Responses
200
OK
application/json
401
Unauthorized
application/json
403
Forbidden
application/json
404
Account not found
application/json
500
Internal error
application/json
get
GET /v0/platform/accounts/{idOrKey}/discount_rate HTTP/1.1
Host: api.alluvial.finance
Authorization: Bearer JWT
Accept: */*
{
  "account_id": "36cc991e-d4r5-422c-8248-ac356e800fc1",
  "created_at": "2023-12-31T23:59:59Z",
  "removed_at": "2023-12-31T23:59:59Z",
  "target_fee_rate": 0.05
}

Create a discounted fee rate for an account

post

Create a discounted fee rate for an account

Authorizations
Path parameters
idOrKeystringRequired

Account ID or Key of the account to add discounted fee rate to

Body
target_fee_ratenumberOptionalExample: 0.05
Responses
200
OK
application/json
400
Invalid discount rate" {message:discountRateValidation}
application/json
401
Unauthorized
application/json
403
Forbidden
application/json
404
Account not found
application/json
409
Discounted fee rate already exists for this account. To modify it, please use the update api endpoint.
application/json
500
Internal error
application/json
post
POST /v0/platform/accounts/{idOrKey}/discount_rate HTTP/1.1
Host: api.alluvial.finance
Authorization: Bearer JWT
Content-Type: application/json
Accept: */*
Content-Length: 24

{
  "target_fee_rate": 0.05
}
{
  "account_id": "36cc991e-d4r5-422c-8248-ac356e800fc1",
  "created_at": "2023-12-31T23:59:59Z",
  "removed_at": "2023-12-31T23:59:59Z",
  "target_fee_rate": 0.05
}

Update a discounted fee rate for an account

patch

Update a discounted fee rate for an account. If the discount rate already exists, it will be updated. A TargetFeeRate of 0.1 means no discount.

Authorizations
Path parameters
idOrKeystringRequired

Account ID or Key of the account to update discounted fee rate for

Body
target_fee_ratenumberOptionalExample: 0.05
Responses
200
OK
application/json
304
Discount rate is already set to the requested value
application/json
400
Invalid discount rate" {message:discountRateValidation}
application/json
401
Unauthorized
application/json
403
Forbidden
application/json
404
Account not found
application/json
500
Internal error
application/json
patch
PATCH /v0/platform/accounts/{idOrKey}/discount_rate HTTP/1.1
Host: api.alluvial.finance
Authorization: Bearer JWT
Content-Type: application/json
Accept: */*
Content-Length: 24

{
  "target_fee_rate": 0.05
}
{
  "account_id": "36cc991e-d4r5-422c-8248-ac356e800fc1",
  "created_at": "2023-12-31T23:59:59Z",
  "removed_at": "2023-12-31T23:59:59Z",
  "target_fee_rate": 0.05
}