Core API and Subsystems Guides

In this section, we'll describe implementation and integration aspects of our (REST)APIs, Web-Assembly (WASM) client-side browser components, mobile apps and ready-made subsystems.

Additionally there will be examples provided for your client-side development, wherever that might be a bit more complex then usual JS/HTML approach. In most of the cases, you would want to use either our WASM components or our mobile apps on the client-side, but there are also situations where you might wish to entirely build your own client-side components, and we'll try to help you with that. In the latter case, we'll provide you with some code-examples, just to get you started quicker. In this case, you'll be only using our REST-API.

Calls and format

Api is located on https://api.machinesense.net/.

Calls are performed in standard REST formats, thus you'll be familiar with that. It's simply a web service accepting and returning JSON data.

Images and audio data should be, by default, b64 encoded. Images are accepted as PNG or JPG. Audio data best sent as AAC. Videos as MPG4.

Alternatively, you can send your data as multi-part form data, if you prefer this approach.

General API guideline

MachineSense APIs are, generally, of two types:

  • Single-call APIs where you, as a developer, provide API-key together with specifying the action required from our APIs and accompanying data (such as photo of a face, for example, in b64/png) as well as some call-options, and expect direct response to some of your urls/webhooks.
  • Two-call APIs where you, as a developer, first call our API to get a session-id, and then pass that session-id from the client-side to our service in order to identify a particular call, or pass to the user for input in our mobile app or client-side component. After that, you expect response to some of your urls/webhooks.

Process is, thus (from the beginning):

  1. Get your API-key and set your API options (defaults, webhooks, etc.) after logging-in,
  2. If single-call, make that call from your back-end to one of our APIs.
    If Two-call, initiate a session and than make a call from the client-side.
    (for examples, see API section),
  3. Expect response to the url/webhook you specified for that API key in your partner-settings.

Some exceptions to this are implementations where our mobile apps or client-side components are used as a part of the solution.

See examples on these exceptions at KYC with NFC or KYC with scan.

For more details, see the API documentation section.