# Create Customer

## Create a Customer

<mark style="color:green;">`POST`</mark> `https://sandbox.pgecom.com/api/v1/buisness/customer`

#### Headers

| Name                                            | Type   | Description    |
| ----------------------------------------------- | ------ | -------------- |
| authorization<mark style="color:red;">\*</mark> | String | Bearer `token` |

#### Request Body

| Name                                        | Type    | Description             |
| ------------------------------------------- | ------- | ----------------------- |
| lastName<mark style="color:red;">\*</mark>  | String  | less than 30 characters |
| phone<mark style="color:red;">\*</mark>     | String  |                         |
| id                                          | String  |                         |
| line1                                       | String  |                         |
| line2                                       | String  |                         |
| city<mark style="color:red;">\*</mark>      | String  |                         |
| country                                     | String  |                         |
| state                                       | String  |                         |
| postal\_code                                | String  |                         |
| notes                                       | Boolean |                         |
| userID                                      | String  |                         |
| email<mark style="color:red;">\*</mark>     | String  |                         |
| firstName<mark style="color:red;">\*</mark> | String  |                         |
| createdAt                                   | String  |                         |
| updatedAt                                   | String  |                         |

{% tabs %}
{% tab title="200: OK " %}

```json

{
    "email": "james@gmail.com",
    "firstName": "James",
    "lastName": "Peter",
    "phone": "+1 404 825 3444",
    "line1": "9700 Medlock Bridge Road",
    "line2": "",
    "city": "Kennewick",
    "country": "United States",
    "state": "WA",
    "postal_code": "993398",
    "notes": "This is simple demo",
    "userID": "6bc4f4cf-d562-4306-9192-a2eaf4fa9789",
    "createdAt": "",
    "updatedAt": "",
    "id": "4a3ce0b8-efdc-4640-ac23-099134d1a881"
}
```

{% endtab %}

{% tab title="401: Unauthorized " %}

```json
{
    "message": "Token not valid"
}
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.pgecom.com/api-endpoint/deprecated/card/create-customer.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
