后台管理系统中的授权

针对后台管理系统 API 进行服务器间请求身份验证。

面向管理员

The B2COPY API uses bearer-token authorization. Call the sign-in method below to get an access/refresh token pair, then include the access token in the Authorization: Bearer <token> header of every subsequent request.

Prerequisite

To obtain tokens you must already be registered in the Back Office and have credentials to access it.

Endpoint

POST [host]/api/v2/signin

Request Body

NameTypeRequiredDescription
emailstringYesThe email address used to access the Back Office.
passwordstringYesThe password used to access the Back Office.
curl --location --request POST 'https://host.name/api/v2/signin' \
--data-raw '{
  "email": "username@example.com",
  "password": "Secret123"
}'

Response

The response returns a pair of access and refresh tokens, each with a token string and createdAt / expiresAt timestamps.

{
  "2faRequired": false,
  "accessToken": {
    "token": "eyJ0eXAiOiJKV1Qi…",
    "createdAt": "2024-01-01T00:00:00+00:00",
    "expiresAt": "2024-01-01T00:00:00+00:00"
  },
  "refreshToken": {
    "token": "eyJ0eXAiOiJKV1Qi…",
    "createdAt": "2024-01-01T00:00:00+00:00",
    "expiresAt": "2024-01-01T00:00:00+00:00"
  }
}
还不是 B2COPY 客户?

将 B2COPY 引入您的经纪业务,实现自动驾驶式增长

在现有服务器上部署跟单交易、PAMM 与 MAM,把最优秀的交易员变成增长引擎——含托管、监控与支持。不确定从何开始?联系我们,我们会逐步讲解。

2–4 周

上线时间

$0

基础设施成本

40%+

成交量提升