MultiMarkets API Docs en
HomeGitHubReferenceLanguage
  • Overview
  • Quick Start
    • Status
  • CLIENT API
    • Overview
    • Access
      • Sign
      • Request
      • Limit
      • Error Code
      • API Address
      • API Code
    • Login
      • Captcha
    • Customer
      • Customer registration
      • Replacement Token
      • API Management
        • Apply API
        • Set permissions
        • Delete API
    • Market Data
      • Introduction
      • Limit
      • Error Code
      • Subscribe
        • Ticker
        • Market
        • Cancel
      • Query
        • Heartbeat
        • Historical K-line
    • Open API
      • Readme
        • Sign
        • Request
        • Error Code
        • API Address
      • Order Process
      • Base
        • Symbol Base Info
      • Customer
        • Customer Info
      • Trade
        • Contract order
      • Message
        • Get Msg Token
        • Msg Subscribe
        • Get Msg Token
        • Msg Subscribe
      • More...
    • Auth2 API
      • Readme
      • Auth Code
      • Access Token
      • User Info
      • Refresh Token
    • More...
  • Manager API
    • Overview
    • Access
      • Sign
      • Request
      • Limit
      • Error Code
      • API Address
      • API Code
    • Authorize
    • Basic data
      • Universal dictionaries
      • Company currency
    • Product
      • Product List
    • Customer
      • Customer List
      • Customer registration
      • Customer info
      • Customer Group
      • Account Info
    • Funds
      • Balance Update
      • Get Balance
    • Data Push
    • More...
  • Bridge API
    • Overview
    • Access Instructions
      • Illustrate
      • Sign
      • Request
      • Speed ​​Limit
      • Error Code
      • Product List
    • Basic data
      • Get a list of universal dictionaries
      • Obtain company currency permissions
    • Product Data
      • Product information list
      • Product rule list
    • Customer Management
      • Customer registration
      • Customer list
      • Customer details
      • Customer account cancellation
    • Account Management
      • Add account
      • Update account
      • Check account
      • Delete account
    • Trading interface
      • Check balance
      • Check deposit records
      • Check withdrawal records
      • Query transfer records
      • Place an order
      • Query order
      • Order list
      • Transaction record
      • Current pending order
      • Cancel order
    • News Subscription
      • Notification message description
      • Webhook subscription
      • Information callback notification
  • Webhook API
    • Overview
    • Account balance
    • Execute adjustment balance
    • Cancel adjustment balance
  • Message API
    • Overview
    • Custom message API
  • WEB IFRAME
    • Introduction
    • Process description
  • FAQ
    • How to apply for apikey for an interface?
    • What is the purpose of the public key?
    • What is the interface request timeout?
    • Supported development languages?
    • What are the API call restrictions?
    • How to use APIs more safely?
  • API Reference
    • Manager API
    • Client API
  • CHANGELOGS
    • API
Powered by GitBook
On this page
  • 1. Signature
  • 1.1 Signature Rules
  • 1.2 Signature Example
  • 2.Attachment
  1. CLIENT API
  2. Open API
  3. Readme

Sign

Sign

1. Signature

1.1 Signature Rules

The signature uses the SHA1WithRSA algorithm. The secretKey serves as the key for SHA1WithRSA, and the parameters in param + timestamp serve as the operating objects for SHA1WithRSA. The output obtained is the signature.

  • Step 1: Retrieve the request parameters in the body, sort the parameters alphabetically, and form a string.

    • The sorting method "alphabetical order" means sorting from smallest to largest alphabetically, comparing the first letter first, if the same, compare the second letter, and so on.

    • Remove all double quotes, whether they are from field names or field values.

    • No spaces in between.

    • If the field is null, it is not included in the signature.

  • Step 2: Retrieve the timestamp parameter from the request header and append it to the result of Step 1.

  • Step 3: Use the secretKey to perform SHA1WithRSA on the result from Step 2 to generate the signature.

1.2 Signature Example

Parameter
Value

companyId

220

apiKey

1710e1f6b4b54c15bea72e8669966591

secretKey

MIICeAIBADANBgkqhkiG9w0BAQEFAASCAmIwggJeAgEAAoGBAI5WJjsBgtiuQQZDs5qe8LBDUm2ZSa4gTBJ

Request Parameters:

{"companyId":1,"lang":"zh-CN","customerNo":"86001308"}

Calculate Signature:

  • Step 1: Retrieve the request parameters in the body and sort them alphabetically to form the following string: {“companyId”:1,”customerNo”:”86001308”,”lang”:”zh-CN”}

  • Step 2: Retrieve the timestamp parameter from the request header and append it to the result of Step 1, as follows: {companyId:1,customerNo:86001308,lang:zh-CN}1650361143685

  • Step 3: Use the secretKey to perform SHA1WithRSA on the result from Step 2, the result is: Dihl6oOt5UkaHo9sEouquP3EqbukLX2dAOoKTSGicYryTvH1m9r6vtSLHGutZn7u34/06gjhdpbXRFPdjb51GVHvG75qWXZ1P/boL89xtuja6eTEy9q/aS8R270Q1A+m/MOTxdiifCy0IByrSpCs4VJKaj2d8jlJo2GHznsH+q0=

2.Attachment

PreviousReadmeNextRequest

Last updated 10 months ago

Java version .

demo