Skip to main content
Skip table of contents

Credit Recharging

GET /v3/rechargeProviders

Get current active Recharge providers.

CODE
Headers:
Content-Type: application/json
Authentication: Bearer %access_token%

Authentication:
Grant_type: client_credentials, login_info
Scopes: [ credit ]

Response body:
{
  "providers": [
    {
      "name": "string",
      "reference": "string",
      "description": "string",
      "params": [
        "string",
        0,
        true
      ]
    }
  ],
  "count": 0
}


GET /v3/rechargeProviders/{reference}/payments

Get payments. Logged user MUST have right Manage payments.

CODE
Headers:
Content-Type: application/json
Authentication: Bearer %access_token%

Authentication:
Grant_type: client_credentials, login_info
Scopes: [ credit ]

Response body:
{
  "payments": [
    {
      "id": 0,
      "userId": 0,
      "amount": 0,
      "currency": "string",
      "state": "string",
      "created": "2021-10-21T09:24:43.122Z",
      "updated": "2021-10-21T09:24:43.122Z",
      "expires": "2021-10-21T09:24:43.122Z",
      "paymentNo": 0,
      "provider": "string",
      "description": "string"
    }
  ],
  "count": 0
}


POST /v3/rechargeProviders/{reference}/payments

Create a payment. You must commit the payment to make it effective. Logged user MUST have right Manage payments.

CODE
Headers:
Content-Type: application/json
Authentication: Bearer %access_token%

Authentication:
Grant_type: client_credentials, login_info
Scopes: [ credit ]

Request body:
{
  "userId": 0,
  "description": "string",
  "params": "string"
}

Response body:
{
  "id": "string",
  "userId": 0,
  "amount": 0,
  "description": "string",
  "params": {
    "additionalProp1": "string",
    "additionalProp2": "string",
    "additionalProp3": "string"
  }
}


PATCH /v3/rechargeProviders/{reference}/payments/{id}

Update the payment. Logged user MUST have right Manage payments.

CODE
Headers:
Content-Type: application/json
Authentication: Bearer %access_token%

Authentication:
Grant_type: client_credentials, login_info
Scopes: [ credit ]

Request body:
{
  "description": "string",
  "params": {
    "additionalProp1": "string",
    "additionalProp2": "string",
    "additionalProp3": "string"
  }
}


POST /v3/rechargeProviders/{reference}/payments/{id}/commit

Commit the payment. To make it effective. Logged user MUST have right Manage payments.

CODE
Headers:
Content-Type: application/json
Authentication: Bearer %access_token%

Authentication:
Grant_type: client_credentials, login_info
Scopes: [ credit ]

Response body:
{
  "amount": 0
}


POST /v3/rechargeProviders/{reference}/payments/{id}/rollback

Roll back the payment. Logged user MUST have right Manage payments.

CODE
Headers:
Content-Type: application/json
Authentication: Bearer %access_token%

Authentication:
Grant_type: client_credentials, login_info
Scopes: [ credit ]

Request body:
{
  "reason": "string"
}

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.