# Customers API

- Human documentation: https://www.myrepairapp.com/api-docs/customers
- OpenAPI: https://www.myrepairapp.com/openapi.json
- Last updated: 2026-07-30T23:32:46.276Z

## The Customer Model

The Customer object represents a customer in the system. Below is an example of a Customer object with all possible fields.

```json
{
    "id": "12345",
    "firstName": "John",
    "lastName": "Doe",
    "company": "ACME Corp",
    "primaryPhone": "123-456-7890",
    "contactPhone": "123-456-7890",
    "email": "john.doe@example.com",
    "driversLicense": "123456789",
    "storeCredit": 100.5,
    "preferredContactMethods": ["email", "phone"],
    "billingAgent": "John Smith",
    "netTerms": "30 days",
    "taxExempt": "No",
    "postalCode": "12345",
    "referralSourceId": null,
    "street1": "123 Main St",
    "street2": "Suite 100",
    "country": "US",
    "state": "CA",
    "city": "Los Angeles"
  }
```

### Customer Object Properties

| Field                     | Type     | Required | Description                                           |
| ------------------------- | -------- | -------- | ----------------------------------------------------- |
| `id`                      | `string` | No       | The unique identifier for the customer.               |
| `firstName`               | `string` | Yes      | The customer's first name.                            |
| `lastName`                | `string` | Yes      | The customer's last name.                             |
| `company`                 | `string` | Yes      | The company associated with the customer.             |
| `primaryPhone`            | `string` | Yes      | The customer's primary phone number.                  |
| `contactPhone`            | `string` | No       | An additional contact phone number.                   |
| `email`                   | `string` | No       | The customer's email address.                         |
| `driversLicense`          | `string` | No       | The customer's driver's license number.               |
| `storeCredit`             | `number` | Yes      | The store credit available for the customer.          |
| `preferredContactMethods` | `array`  | Yes      | The customer's preferred methods of contact.          |
| `billingAgent`            | `string` | Yes      | The billing agent responsible for this customer.      |
| `netTerms`                | `string` | Yes      | The payment terms for the customer (e.g., "30 days"). |
| `taxExempt`               | `string` | Yes      | Indicates if the customer is tax-exempt.              |
| `postalCode`              | `string` | Yes      | The postal code for the customer's address.           |
| `referralSourceId`        | `number` | No       | The source that referred the customer, if applicable. |
| `street1`                 | `string` | Yes      | The primary street address of the customer.           |
| `street2`                 | `string` | Yes      | Additional street address information.                |
| `country`                 | `string` | Yes      | The customer's country of residence.                  |
| `state`                   | `string` | Yes      | The state of the customer's address.                  |
| `city`                    | `string` | Yes      | The city of the customer's address.                   |

***

## Customer Resources

### Get all customers

This endpoint returns a list of all customers.

**HTTP Request**

```http
GET https://www.myrepairapp.com/api/v2/customers
```

**Response**

If successful, the response will include a list of all customers.

***

### Create a customer

This endpoint creates a new customer.

**HTTP Request**

```http
POST https://www.myrepairapp.com/api/v2/customers
```

**Request Body**

The request body must contain a valid Customer object.

**Response**

If successful, the response will include the updated customer's details.

***

### Get a customer by ID

This endpoint returns a single customer by ID.

**HTTP Request**

```http
GET https://www.myrepairapp.com/api/v2/customers/{id}
```

**Response**

If successful, the response will include the details of the requested customer.

***

### Update a customer

This endpoint updates a customer's information.

**HTTP Request**

```http
PATCH https://www.myrepairapp.com/api/v2/customers/{id}
```

**Request Body**

The request body must contain a Customer object with the fields to be updated.

**Response**

If successful, the response will include the updated customer's details.

***

### Delete a customer

This endpoint deletes a customer.

**HTTP Request**

```http
DELETE https://www.myrepairapp.com/api/v2/customers/{id}
```

**Response**

If successful, the response will indicate that the customer has been deleted.
