eMOBIQ Documentation
eMOBIQ Platfom
eMOBIQ Server
eMOBIQ Server
  • Editor
    • General
    • Dashboard
    • Module
    • Service
    • Configuration
  • Api
    • General
    • Editing
    • Authentication
    • Method
    • Header
    • Parameter
    • Result
    • Action
    • Test
  • Database
    • General
    • Editing Database
    • Table Content
    • Table Relations
    • Table Structure
  • Scheduler
    • General
    • Editing
    • Configuration
    • Action
    • Test
  • Function
    • Concurrency
      • Concurrency.spawnThread
    • Connector
      • Connector.restCall
      • Connector.soapCall
    • Control
      • Control.conditional
      • Control.forLoop
      • Control.map
    • Conversion
      • Conversion.base64ToText
      • Conversion.jsonToObject
      • Conversion.textToBase64
      • Conversion.toBoolean
      • Conversion.toList
      • Conversion.toNull
      • Conversion.toNumber
      • Conversion.toObject
      • Conversion.toText
    • Dataset
      • Dataset.insert
      • Dataset.read
      • Dataset.remove
      • Dataset.update
    • Datetime
      • DateTime.difference
      • DateTime.get
      • DateTime.update
    • File
      • File.copy
      • File.export
      • File.read
      • File.remove
      • File.write
    • Format
      • Format.dateTime
      • Format.number
    • List
      • List.average
      • List.combine
      • List.count
      • List.fill
      • List.find
      • List.includes
      • List.insertFirst
      • List.insertLast
      • List.max
      • List.min
      • List.removeFirst
      • List.removeLast
      • List.sort
      • List.sum
    • Log
      • Log.write
    • Logic
      • Logic.and
      • Logic.equal
      • Logic.greaterThan
      • Logic.greaterThanOrEqual
      • Logic.lessThan
      • Logic.lessThanOrEqual
      • Logic.not
      • Logic.notEqual
      • Logic.or
    • Mail
      • Mail.send
    • Math
      • Math.absolute
      • Math.add
      • Math.atan2
      • Math.cos
      • Math.divide
      • Math.modulo
      • Math.multiply
      • Math.pi
      • Math.power
      • Math.round
      • Math.sin
      • Math.square
      • Math.squareRoot
      • Math.subtract
      • Math.tan
    • Object
      • Object.insert
      • Object.remove
    • Result
      • Result.setAPI
      • Result.setUserDefined
    • Text
      • Text.combine
    • Validation
      • Validation.isEmail
      • Validation.isList
      • Validation.isNull
      • Validation.isNumber
    • Variable
      • Variable.get
      • Variable.getAttribute
      • Variable.set
      • Variable.setAttribute
Powered by GitBook
On this page
  • Description
  • Example use case
  • Supported types
  • How to use
  • Note
  1. Api

Authentication

PreviousEditingNextMethod

Last updated 1 year ago

Description

Authentication can be applied to this API, which provide access protections and will require privilege to use them. This is useful if you want to restrict some parts of the API to limited users and not make them public.

Example use case

  • Allow only registered users to access certain exclusive Actions.

  • Allow only administrators account to access sensitive Actions.

Supported types

  1. Basic Auth: Uses username and password pair to gain access for authorization, and will need to be attached on client request.

  2. OAuth2: Uses token, which the client needs to obtain from a specialized endpoint. Tokens need to be attached on client request.

    • For more information, you may look on the OAuth2 reference, which is accessible by selecting the icon button beside the Authentication dropdown.

How to use

  1. Highlight an Action or Folder you want to have Authentication on.

    • Action: Selecting an Action will apply protection on that particular item.

    • Folder: Selection a Folder will apply protection on all Actions inside them, including Action inside sub-folders.

  2. On the top right, under Authentication dropdown, select it to reveal available Authentication for use. You may also edit Authentication, or remove it entirely from API

    • To create new Authentication, select Edit.

  3. When selecting Edit, a configuration popup will be shown, and allows Authentication to be configured and edited.

    • Authentication can be used more than one time, and can be applied to multiple parts of the API.

  4. The following fields are available.

    • Name: a unique name to identify this Authentication.

    • Type: Basic Auth or OAuth2.

    • DB Connection: which database to use.

    • Table Reference: which table to use.

    • Username: which field to search for username.

    • Password: which field to search for password.

Note

Please create the desired database first in the Database module to usa it when configuring the Authentication.