> For the complete documentation index, see [llms.txt](https://docs.payengine.co/payengine-api-v2.5/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.payengine.co/payengine-api-v2.5/onboarding/invite-existing-merchant.md).

# Invite Existing Merchant

## Invite existing merchant

<mark style="color:green;">`POST`</mark>`https://<Platform-host>/merchant/:merchant_id/invite`

Retrieve the details of a merchant.

#### Path Paremeters

| Name         | Tyoe   | Description                                               |
| ------------ | ------ | --------------------------------------------------------- |
| merchant\_id | string | Merchant ID of a merchant to whom invite needs to be sent |

#### Request Body

| Name                                    | Type   | Description                                             |
| --------------------------------------- | ------ | ------------------------------------------------------- |
| name<mark style="color:red;">\*</mark>  | string | Merchant name                                           |
| email<mark style="color:red;">\*</mark> | string | Merchant's email address to which invite has to be sent |
| external\_id                            | string | Merchant ID from your system (optional)                 |

{% tabs %}
{% tab title="200 Response" %}

| Name          | Type   | Description                                     |
| ------------- | ------ | ----------------------------------------------- |
| message       | string | Success or failure message of the invite        |
| data.id       | string | Merchant ID                                     |
| data.email    | string | Mechant's email address to which email was sent |
| {% endtab %}  |        |                                                 |
| {% endtabs %} |        |                                                 |

### Sample Request

{% tabs %}
{% tab title="Sample Request" %}

```javascript
{
  "email": "test@test.com"
}
```

{% endtab %}

{% tab title="Sample Response" %}

```json
{
    "message": "Invitation to test@test.com successfully sent",
    "data": {
        "id": "d44f7f86-204d-419f-80ba-a50a15607600",
        "email": "test@test.com"
    }
}
```

{% endtab %}
{% endtabs %}
