In this chapter, you will understand how to connect FsTK APIs with right authentication.

Table of Contents

  1. Prerequisite
  2. Authentication / Authorization
  3. Next step

Prerequisite

  1. Please sign up an account on https://test.fstk.io or https://engine.fstk.io.

    Notice account data are NOT shared across both platform

    • test.fstk.io is Tokeneden built on Kovan Testnet for agile software development, testing & demo.
    • engine.fstk.io is official Tokeneden built on Ethereum Mainnet.
  2. Please take a look at your asset balances of ETHFSTFIL and FST Service Gas.

    Please remember that assets on test.fstk.io belongs to Kovan Testnet; assets on engine.fstk.io belongs to Mainnet

    • ETH is Ether, a small amount will be given to new accounts on test.fstk.io.
    • FST is Funder Smart Token, a fundamental Utility Token within FST Network and will be given to new accounts on test.fstk.io.
    • FIL is FundersToken Initialisation License as Token Issuance License, 1 FIL will be given to new accounts on test.fstk.io.
    • FST Service Gas is the FsTK module usage fee for Token Issuer, balance is shown at User Profile on the top right corner.
  3. Please prepare your API testing tools

Authentication / Authorization

  1. Retrieve Access Web Token (JWT)

    Please use accounts & passwords on https://test.fstk.io or https://engine.fstk.io. Notice that it is https, not http.

    Hereinafter we will use https://test.fstk.io as endpoints.

    • Using cURL
    • Using JavaScript
    • Response
  2. Store and use access_token from Response

    Format of access_token is JSON Web Token, please refer to jwt.io

    access_token will expire after 24 hours.

    In the future, except API for sign-ins, please assign access_token in authorization within http request header.

    Notice the string, Bearer , must be added before access_token then authorization header will work.

Next step

Next step