---
title: Create Merchant API
slug: generic-onboarding/create-merchant-api
description: Learn how to use the powerful API described in this document to effortlessly create application instances within a platform. With detailed instructions, sample requests and responses, and a comprehensive field description, you'll quickly grasp the necessa
createdAt: 2023-02-14T12:51:18.000Z
---

# Introduction

The API is used to create an application instance within our platform and this is created within a realm for a particular flow. The API response will provide an identification of the application within the realm. (The response contains the "merchant id" and "signzyAppId" which can be used as a unique identifier of the application within the platform.)

# Sample Request

::::Tabs
:::Tab{title="Preproduction"}
```curl
curl --location --globoff 'https://go-preproduction.signzy.app/api/v1/applications/{{Applicationid}}/merchants' \
--header 'Authorization: <Authorization token>' \
--header 'Content-Type: application/json' \
--data '{
    "name": <name>,
    "username": <username>,
    "password": "..password..",
    "email": "..email..",
    "mobile": "..mobile..",
    "realm": "..realmid..",    
    "flowId": "..flowid.."
}'
```
:::
::::

## Request Field Description

| **Key**             | **Required/Optional** | **Data Type** | **Description**                                    |
| ------------------- | --------------------- | ------------- | -------------------------------------------------- |
| **Path Parameters** |                       |               |                                                    |
| applicationId       | Required              | string        | applicationId returned from the backops user login |
| **Headers**         |                       |               |                                                    |
| Authorization       | Required              | string        | access-token returned from backops login request   |
| Content-Type        | Required              | string        | application/json                                   |
| password            | Required              | string        | password of the user                               |
| **Body Parameters** |                       |               |                                                    |
| flowId              | Required              | string        | Flow that is assigned to the end user              |
| name                | Optional              | string        | name of the user                                   |
| username            | Optional              | string        | username for the user                              |
| password            | Optional              | string        | password of the user                               |
| mobile              | Required\*            | string        | mobile number of the user                          |
| email               | Required\*            | string        | email of the user                                  |
| realm               | Required              | string        | realm returned from the backops login request      |

# Sample Response

:::CodeblockTabs
200: OK

```json
{
   "id": "63ec5c61d405cb001760xxxx",
   "name": "..name..",
   "email": "..email..",
   "mobile": "..mob_no..",
   "username": "cf064xx8",
   "flowId": "63e3b459540007001714xxxx",
   "realm": "..realm_name..",
   "signzyAppId": "ABCDxxx545",
   "applicationId": "628e20be9b11c5d9d418xxxx",
   "distributorId": "628e23439b11c5d9d418xxxx",
   "backopsUserId": "",
   "realmId": "628e20be9b11c5d9d418xxxx",
   "autogeneratedUsername": true,
   "regex": "",
   "onboardingStartDate": 1676434529407,
   "status": "new",
   "flowDetails": {
       "name": "..flow_name",
       "type": "mainflow"
   },
   "autoLoginUrl": "..url..",
   "loginUrl": "..url..",
   "shortLoginUrl": "..url..",
   "shortAutoLoginUrl": "..url.."
}

```

400: Bad Request

```json
{
    "error":{ 
           "statusCode":400, 
           "name":"Error", 
           "message":"realm is required",
            "code":"REALM_REQUIRED"
         }
 }

```

401: Unauthorized

```json
{ 
    "error":{ 
            "statusCode":401, 
            "name":"Error", 
            "message":"Authorization Required", 
            "code":"AUTHORIZATION_REQUIRED" 
          } 
}

```

404: Not Found

```json
{
   "error": {
       "statusCode": 404,
       "name": "Error",
       "message": "Shared class \"Patron\" has no method handling POST /login/1232",
       "status": 404   }
}

```
:::

## Response Field Description

| **Key**           | **Data Type** | **Description**                                                                                                    |
| ----------------- | ------------- | ------------------------------------------------------------------------------------------------------------------ |
| name              | string        | Name for the end user whose onboarding needs to be conducted                                                       |
| username          | string        | Username of the end user (needs to be provided for them to be able to log in)                                      |
| email             | string        | Email for the end user whose onboarding needs to be conducted                                                      |
| mobile            | string        | Phone for the end user whose onboarding needs to be conducted                                                      |
| realm             | string        | Realm returned from the backops user login                                                                         |
| flowId            | string        | Flow that is to be assigned to the end user                                                                        |
| variableN         | string        | These are predefined input parameters which the integrator needs to send to Signzy before the start of the journey |
| signzyAppId       | string        | This is the reference id which is used to identify the application                                                 |
| status            | string<br />  | The current status of the application. By default, this is "New" for a newly created application.                  |
| qr                | string        | This is a a QR code for starting the onboarding journey                                                            |
| autoLoginUrl      | string<br />  | This is the URL where the merchant needs to be redirected to commence the onboarding journey.                      |
| shortAutoLoginUrl | string        | Shortened autologin URL                                                                                            |

:::hint{type="info"}
### Getting help

Please feel free to contact us if you have any questions, require clarification, or have ideas for how to make the documents or any of our services better.


You can reach out to us at [help@signzy.com](#).
:::

