---
updatedAt: 2026-04-08T00:12:31.000Z
agentTools:
  projectIndex: https://docs.pelcro.com/v2.4/llms.txt
---

# Create vendor

Create a new vendor.

## Overview

Create a new vendor with contact information. The vendor is created as a user with type `vendor` on the site.

**Example:** Add a freelance writer as a vendor so you can create bills for their work.

***

## Important Behaviors

* **Email uniqueness**: The email must be unique among vendors on the same site.
* **Event fired**: `vendor.created` event is dispatched after successful creation.

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "core-api",
    "version": "1.88"
  },
  "servers": [
    {
      "url": "https://www.pelcro.com/api/v1/core"
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "apiKey",
        "in": "header",
        "name": "Authorization",
        "x-bearer-format": "bearer"
      },
      "sec1": {
        "type": "apiKey",
        "in": "query",
        "name": "site_id"
      }
    }
  },
  "security": [
    {
      "sec0": [],
      "sec1": []
    }
  ],
  "paths": {
    "/vendors": {
      "post": {
        "summary": "Create vendor",
        "description": "Create a new vendor.",
        "operationId": "api-core-create-vendor",
        "parameters": [
          {
            "name": "site_id",
            "in": "query",
            "description": "The unique identifier of the site associated with your account.",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "default": "Bearer eyJ***"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "first_name",
                  "last_name",
                  "email"
                ],
                "properties": {
                  "first_name": {
                    "type": "string",
                    "maxLength": 255,
                    "description": "Vendor first name. Required."
                  },
                  "last_name": {
                    "type": "string",
                    "maxLength": 255,
                    "description": "Vendor last name. Required."
                  },
                  "email": {
                    "type": "string",
                    "format": "email",
                    "maxLength": 255,
                    "description": "Vendor email. Must be unique among vendors on the site."
                  },
                  "phone": {
                    "type": "string",
                    "maxLength": 20,
                    "description": "Phone number."
                  },
                  "birthdate": {
                    "type": "string",
                    "format": "date",
                    "description": "Birthdate in YYYY-MM-DD format."
                  },
                  "job_title": {
                    "type": "string",
                    "maxLength": 255,
                    "description": "Job title."
                  },
                  "company": {
                    "type": "string",
                    "maxLength": 255,
                    "description": "Company name."
                  },
                  "address": {
                    "type": "string",
                    "maxLength": 255,
                    "description": "Street address."
                  },
                  "city": {
                    "type": "string",
                    "maxLength": 100,
                    "description": "City."
                  },
                  "state": {
                    "type": "string",
                    "maxLength": 100,
                    "description": "State or province."
                  },
                  "country": {
                    "type": "string",
                    "maxLength": 100,
                    "description": "Country."
                  },
                  "postal_code": {
                    "type": "string",
                    "maxLength": 20,
                    "description": "Postal/ZIP code."
                  },
                  "metadata": {
                    "type": "object",
                    "description": "Custom metadata key-value pairs."
                  },
                  "delivery_service_area_prompt": {
                    "type": "string",
                    "description": "AI delivery service area prompt."
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "integer"
                        },
                        "vendor_id": {
                          "type": "integer"
                        },
                        "name": {
                          "type": "string"
                        },
                        "first_name": {
                          "type": "string"
                        },
                        "last_name": {
                          "type": "string"
                        },
                        "email": {
                          "type": "string"
                        },
                        "phone": {
                          "type": "string",
                          "nullable": true
                        },
                        "birthdate": {
                          "type": "string",
                          "nullable": true
                        },
                        "job_title": {
                          "type": "string",
                          "nullable": true
                        },
                        "delivery_service_area_prompt": {
                          "type": "string",
                          "nullable": true
                        },
                        "bills_count": {
                          "type": "integer"
                        },
                        "total_billed": {
                          "type": "number"
                        },
                        "payout_ready": {
                          "type": "boolean"
                        },
                        "metadata": {
                          "type": "object",
                          "nullable": true
                        },
                        "created_at": {
                          "type": "integer"
                        },
                        "updated_at": {
                          "type": "integer"
                        }
                      }
                    },
                    "status": {
                      "type": "string"
                    }
                  }
                },
                "examples": {
                  "Result": {
                    "value": "{\n  \"data\": {\n    \"id\": 100,\n    \"vendor_id\": 50,\n    \"name\": \"Jane Smith\",\n    \"first_name\": \"Jane\",\n    \"last_name\": \"Smith\",\n    \"email\": \"jane.smith@example.net\",\n    \"phone\": \"+1-555-0123\",\n    \"birthdate\": null,\n    \"job_title\": \"Freelance Writer\",\n    \"delivery_service_area_prompt\": null,\n    \"bills_count\": 0,\n    \"total_billed\": 0,\n    \"payout_ready\": false,\n    \"metadata\": null,\n    \"created_at\": 1650974042,\n    \"updated_at\": 1650974042\n  },\n  \"status\": \"success\"\n}"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Invalid request.",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": {
                      "error": {
                        "status": 400,
                        "message": "Invalid request, please try again."
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthenticated.",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": {
                      "error": "Unauthenticated."
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated": false,
        "x-readme": {}
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```

# Sibling pages

* [List vendors](https://docs.pelcro.com/v2.4/reference/api-core-list-vendors.md)
* [Get vendor](https://docs.pelcro.com/v2.4/reference/api-core-get-vendor.md)
* [Update vendor](https://docs.pelcro.com/v2.4/reference/api-core-update-vendor.md)
* [Delete vendor](https://docs.pelcro.com/v2.4/reference/api-core-delete-vendor.md)
* [Export vendors](https://docs.pelcro.com/v2.4/reference/api-core-export-vendors.md)
* [Payout Details](https://docs.pelcro.com/v2.4/reference/api-core-vendor-payout-details.md)