# Propetware API

Version: 1.0.0

## Servers

Production environment
```
https://api.propetware.com/v1
```

## Security

### ApiKeyAuth

Type: apiKey
In: header
Name: X-API-Key

### ApiKeyAuthAlt

Authorization: ApiKey YOUR_API_KEY

Type: apiKey
In: header
Name: Authorization

### BearerAuth

Type: http
Scheme: bearer
Bearer Format: JWT

## Download OpenAPI description

[Propetware API](https://developers.propetware.com/_bundle/apis/openapi-v1.yaml)

## Authentication

Customer authentication and JWT token management

### Login customer

 - [POST /auth/login](https://developers.propetware.com/apis/openapi-v1/authentication/logincustomer.md): Authenticate a customer and receive JWT token

### Refresh JWT token

 - [POST /auth/refresh](https://developers.propetware.com/apis/openapi-v1/authentication/refreshtoken.md): Refresh an existing JWT token

### Logout customer

 - [POST /auth/logout](https://developers.propetware.com/apis/openapi-v1/authentication/logoutcustomer.md): Invalidate the current JWT token

### Get current customer

 - [GET /auth/me](https://developers.propetware.com/apis/openapi-v1/authentication/getcurrentcustomer.md): Get the currently authenticated customer's information

## Accounts

Operations related to accounts

### List accounts

 - [GET /accounts](https://developers.propetware.com/apis/openapi-v1/accounts/listaccounts.md): Retrieve a list of accounts the current credentials have access to. It will return more than one account for multi-location API keys.

### Get account details

 - [GET /accounts/{accountId}](https://developers.propetware.com/apis/openapi-v1/accounts/getaccount.md): Retrieve details of a specific account

### List pending reason options

 - [GET /accounts/{accountId}/pendingReasonOptions](https://developers.propetware.com/apis/openapi-v1/accounts/listpendingreasonoptions.md): Retrieve all pending reason options for an account, optionally filtered by service type

## Customers

Operations related to customers

### List customers

 - [GET /accounts/{accountId}/customers](https://developers.propetware.com/apis/openapi-v1/customers/listcustomers.md): Retrieve a list of customers for an account

### Create customer

 - [POST /accounts/{accountId}/customers](https://developers.propetware.com/apis/openapi-v1/customers/createcustomer.md): Create a new customer

### Get customer details

 - [GET /accounts/{accountId}/customers/{customerId}](https://developers.propetware.com/apis/openapi-v1/customers/getcustomer.md): Retrieve details of a specific customer

### Update customer

 - [PATCH /accounts/{accountId}/customers/{customerId}](https://developers.propetware.com/apis/openapi-v1/customers/updatecustomer.md): Update a customer

## Customer Fields

Operations related to customer form fields (standard and custom)

### Get all customer form fields

 - [GET /accounts/{accountId}/customerFields](https://developers.propetware.com/apis/openapi-v1/customer-fields/getcustomerfields.md): Retrieve all customer form fields (standard and custom) for an account

### Get standard customer fields

 - [GET /accounts/{accountId}/customerFields/standard](https://developers.propetware.com/apis/openapi-v1/customer-fields/getstandardcustomerfields.md): Retrieve standard customer form fields for an account

### Update standard customer fields

 - [PATCH /accounts/{accountId}/customerFields/standard](https://developers.propetware.com/apis/openapi-v1/customer-fields/updatestandardcustomerfields.md): Update properties of standard customer form fields

### List custom customer fields

 - [GET /accounts/{accountId}/customerFields/custom](https://developers.propetware.com/apis/openapi-v1/customer-fields/listcustomcustomerfields.md): Retrieve all custom customer form fields for an account

### Create custom customer field

 - [POST /accounts/{accountId}/customerFields/custom](https://developers.propetware.com/apis/openapi-v1/customer-fields/createcustomcustomerfield.md): Create a new custom customer form field

### Get custom customer field

 - [GET /accounts/{accountId}/customerFields/custom/{fieldId}](https://developers.propetware.com/apis/openapi-v1/customer-fields/getcustomcustomerfield.md): Retrieve a specific custom customer form field

### Update custom customer field

 - [PATCH /accounts/{accountId}/customerFields/custom/{fieldId}](https://developers.propetware.com/apis/openapi-v1/customer-fields/updatecustomcustomerfield.md): Update a custom customer form field

### Delete custom customer field

 - [DELETE /accounts/{accountId}/customerFields/custom/{fieldId}](https://developers.propetware.com/apis/openapi-v1/customer-fields/deletecustomcustomerfield.md): Delete a custom customer form field

### Reorder custom customer fields

 - [PATCH /accounts/{accountId}/customerFields/custom/reorder](https://developers.propetware.com/apis/openapi-v1/customer-fields/reordercustomcustomerfields.md): Reorder custom customer form fields

## Pets

Operations related to pets

### List pets

 - [GET /accounts/{accountId}/customers/{customerId}/pets](https://developers.propetware.com/apis/openapi-v1/pets/listpets.md): Retrieve a list of pets for a customer

### Create pet

 - [POST /accounts/{accountId}/customers/{customerId}/pets](https://developers.propetware.com/apis/openapi-v1/pets/createpet.md): Create a new pet for a customer

### Get pet details

 - [GET /accounts/{accountId}/customers/{customerId}/pets/{petId}](https://developers.propetware.com/apis/openapi-v1/pets/getpet.md): Retrieve details of a specific pet

### Update pet

 - [PATCH /accounts/{accountId}/customers/{customerId}/pets/{petId}](https://developers.propetware.com/apis/openapi-v1/pets/updatepet.md): Update a pet

## Pet Fields

Operations related to pet form fields (standard and custom)

### Get all pet form fields

 - [GET /accounts/{accountId}/petFields](https://developers.propetware.com/apis/openapi-v1/pet-fields/getpetfields.md): Retrieve all pet form fields (standard and custom) for an account

### Get standard pet fields

 - [GET /accounts/{accountId}/petFields/standard](https://developers.propetware.com/apis/openapi-v1/pet-fields/getstandardpetfields.md): Retrieve standard pet form fields for an account

### Update standard pet fields

 - [PATCH /accounts/{accountId}/petFields/standard](https://developers.propetware.com/apis/openapi-v1/pet-fields/updatestandardpetfields.md): Update properties of standard pet form fields

### List custom pet fields

 - [GET /accounts/{accountId}/petFields/custom](https://developers.propetware.com/apis/openapi-v1/pet-fields/listcustompetfields.md): Retrieve all custom pet form fields for an account

### Create custom pet field

 - [POST /accounts/{accountId}/petFields/custom](https://developers.propetware.com/apis/openapi-v1/pet-fields/createcustompetfield.md): Create a new custom pet form field

### Get custom pet field

 - [GET /accounts/{accountId}/petFields/custom/{fieldId}](https://developers.propetware.com/apis/openapi-v1/pet-fields/getcustompetfield.md): Retrieve a specific custom pet form field

### Update custom pet field

 - [PATCH /accounts/{accountId}/petFields/custom/{fieldId}](https://developers.propetware.com/apis/openapi-v1/pet-fields/updatecustompetfield.md): Update a custom pet form field

### Delete custom pet field

 - [DELETE /accounts/{accountId}/petFields/custom/{fieldId}](https://developers.propetware.com/apis/openapi-v1/pet-fields/deletecustompetfield.md): Delete a custom pet form field

### Reorder custom pet fields

 - [PATCH /accounts/{accountId}/petFields/custom/reorder](https://developers.propetware.com/apis/openapi-v1/pet-fields/reordercustompetfields.md): Reorder custom pet form fields

## Orders

Operations related to orders

### List orders

 - [GET /accounts/{accountId}/orders](https://developers.propetware.com/apis/openapi-v1/orders/listorders.md): Retrieve a list of orders for an account

### List orders by customer

 - [GET /accounts/{accountId}/customers/{customerId}/orders](https://developers.propetware.com/apis/openapi-v1/orders/listordersbycustomer.md): Retrieve a list of orders for a specific customer

### Get order details

 - [GET /accounts/{accountId}/orders/{orderId}](https://developers.propetware.com/apis/openapi-v1/orders/getorder.md): Retrieve a single order by ID

## Taxes

Operations related to account taxes

### List taxes

 - [GET /accounts/{accountId}/taxes](https://developers.propetware.com/apis/openapi-v1/taxes/listtaxes.md): Retrieve a list of taxes for an account

## Notes

Operations related to customer, pet, and order notes

### List customer notes

 - [GET /accounts/{accountId}/customers/{customerId}/notes](https://developers.propetware.com/apis/openapi-v1/notes/listcustomernotes.md): Retrieve all notes for a specific customer

### Create customer note

 - [POST /accounts/{accountId}/customers/{customerId}/notes](https://developers.propetware.com/apis/openapi-v1/notes/createcustomernote.md): Create a new note for a customer

### List pet notes

 - [GET /accounts/{accountId}/customers/{customerId}/pets/{petId}/notes](https://developers.propetware.com/apis/openapi-v1/notes/listpetnotes.md): Retrieve all notes for a specific pet

### Create pet note

 - [POST /accounts/{accountId}/customers/{customerId}/pets/{petId}/notes](https://developers.propetware.com/apis/openapi-v1/notes/createpetnote.md): Create a new note for a pet

### List order notes

 - [GET /accounts/{accountId}/orders/{orderId}/notes](https://developers.propetware.com/apis/openapi-v1/notes/listordernotes.md): Retrieve all notes for a specific order

### Create order note

 - [POST /accounts/{accountId}/orders/{orderId}/notes](https://developers.propetware.com/apis/openapi-v1/notes/createordernote.md): Create a new note for an order

### Update customer note

 - [PATCH /accounts/{accountId}/customers/{customerId}/notes/{noteId}](https://developers.propetware.com/apis/openapi-v1/notes/updatecustomernote.md): Update an existing customer note

### Delete customer note

 - [DELETE /accounts/{accountId}/customers/{customerId}/notes/{noteId}](https://developers.propetware.com/apis/openapi-v1/notes/deletecustomernote.md): Delete an existing customer note

### Update pet note

 - [PATCH /accounts/{accountId}/customers/{customerId}/pets/{petId}/notes/{noteId}](https://developers.propetware.com/apis/openapi-v1/notes/updatepetnote.md): Update an existing pet note

### Delete pet note

 - [DELETE /accounts/{accountId}/customers/{customerId}/pets/{petId}/notes/{noteId}](https://developers.propetware.com/apis/openapi-v1/notes/deletepetnote.md): Delete an existing pet note

### Update order note

 - [PATCH /accounts/{accountId}/orders/{orderId}/notes/{noteId}](https://developers.propetware.com/apis/openapi-v1/notes/updateordernote.md): Update an existing order note

### Delete order note

 - [DELETE /accounts/{accountId}/orders/{orderId}/notes/{noteId}](https://developers.propetware.com/apis/openapi-v1/notes/deleteordernote.md): Delete an existing order note

### Update note (generic)

 - [PATCH /accounts/{accountId}/notes/{noteId}](https://developers.propetware.com/apis/openapi-v1/notes/updatenote.md): Update an existing note (alternative endpoint without parent resource)

### Delete note (generic)

 - [DELETE /accounts/{accountId}/notes/{noteId}](https://developers.propetware.com/apis/openapi-v1/notes/deletenote.md): Delete an existing note (alternative endpoint without parent resource)

## Breeds

Operations related to account breed lists

### List breeds

 - [GET /accounts/{accountId}/breeds](https://developers.propetware.com/apis/openapi-v1/breeds/listbreeds.md): Retrieve all breeds for an account. Optionally filter by species or search by name.

### Create breed

 - [POST /accounts/{accountId}/breeds](https://developers.propetware.com/apis/openapi-v1/breeds/createbreed.md): Create a new breed for an account. If the account has no breeds yet, the master breed list is seeded first.

### Get breed

 - [GET /accounts/{accountId}/breeds/{breedId}](https://developers.propetware.com/apis/openapi-v1/breeds/getbreed.md): Retrieve a specific breed by ID

### Update breed

 - [PATCH /accounts/{accountId}/breeds/{breedId}](https://developers.propetware.com/apis/openapi-v1/breeds/updatebreed.md): Update a breed name and/or species. Affected pets have their breed string regenerated automatically.

### Delete breed

 - [DELETE /accounts/{accountId}/breeds/{breedId}](https://developers.propetware.com/apis/openapi-v1/breeds/deletebreed.md): Delete a breed. The breed ID is removed from all pets that reference it and their breed strings are regenerated.

## Secondary Pet Statuses

Operations related to custom secondary pet status options

### List secondary pet statuses

 - [GET /accounts/{accountId}/secondaryPetStatuses](https://developers.propetware.com/apis/openapi-v1/secondary-pet-statuses/listsecondarypetstatuses.md): Retrieve all custom secondary pet statuses for an account, ordered by item_order.

### Create secondary pet status

 - [POST /accounts/{accountId}/secondaryPetStatuses](https://developers.propetware.com/apis/openapi-v1/secondary-pet-statuses/createsecondarypetstatus.md): Create a new secondary pet status. The new status is appended at the end of the ordering.

### Get secondary pet status

 - [GET /accounts/{accountId}/secondaryPetStatuses/{statusId}](https://developers.propetware.com/apis/openapi-v1/secondary-pet-statuses/getsecondarypetstatus.md): Retrieve a specific secondary pet status by ID

### Update secondary pet status

 - [PATCH /accounts/{accountId}/secondaryPetStatuses/{statusId}](https://developers.propetware.com/apis/openapi-v1/secondary-pet-statuses/updatesecondarypetstatus.md): Rename a secondary pet status.

### Delete secondary pet status

 - [DELETE /accounts/{accountId}/secondaryPetStatuses/{statusId}](https://developers.propetware.com/apis/openapi-v1/secondary-pet-statuses/deletesecondarypetstatus.md): Delete a secondary pet status. Pets that have this status assigned retain their secondary_pet_status_id until manually updated.

## Colour Codes

Operations related to colour code definitions for pets and customers

### List colour codes

 - [GET /accounts/{accountId}/colourCodes](https://developers.propetware.com/apis/openapi-v1/colour-codes/listcolourcodes.md): Retrieve all colour code definitions for an account

### Create colour code

 - [POST /accounts/{accountId}/colourCodes](https://developers.propetware.com/apis/openapi-v1/colour-codes/createcolourcode.md): Create a new colour code definition

### Get next available colour code number

 - [GET /accounts/{accountId}/colourCodes/nextNumber](https://developers.propetware.com/apis/openapi-v1/colour-codes/getnextcolourcodenumber.md): Get the next available number for a colour code type

### Get colour code

 - [GET /accounts/{accountId}/colourCodes/{id}](https://developers.propetware.com/apis/openapi-v1/colour-codes/getcolourcode.md): Retrieve a specific colour code definition

### Update colour code

 - [PATCH /accounts/{accountId}/colourCodes/{id}](https://developers.propetware.com/apis/openapi-v1/colour-codes/updatecolourcode.md): Update a colour code definition

### Delete colour code

 - [DELETE /accounts/{accountId}/colourCodes/{id}](https://developers.propetware.com/apis/openapi-v1/colour-codes/deletecolourcode.md): Delete a colour code definition (removes it from all pets/customers)

## Vaccinations

Operations related to pet vaccination records

### List pet vaccinations

 - [GET /accounts/{accountId}/pets/{petId}/vaccinations](https://developers.propetware.com/apis/openapi-v1/vaccinations/listpetvaccinations.md): Retrieve vaccination records for a specific pet with expiration data

### Create pet vaccination record

 - [POST /accounts/{accountId}/pets/{petId}/vaccinations](https://developers.propetware.com/apis/openapi-v1/vaccinations/createpetvaccination.md): Create a new vaccination expiration record for a pet

### Update pet vaccination record

 - [PATCH /accounts/{accountId}/pets/{petId}/vaccinations/{expirationId}](https://developers.propetware.com/apis/openapi-v1/vaccinations/updatepetvaccination.md): Update an existing vaccination expiration record for a pet

### Delete pet vaccination record

 - [DELETE /accounts/{accountId}/pets/{petId}/vaccinations/{expirationId}](https://developers.propetware.com/apis/openapi-v1/vaccinations/deletepetvaccination.md): Soft-delete a vaccination expiration record for a pet

### List vaccination types

 - [GET /accounts/{accountId}/vaccinationTypes](https://developers.propetware.com/apis/openapi-v1/vaccinations/listvaccinationtypes.md): Retrieve all vaccination types configured for an account

### Create vaccination type

 - [POST /accounts/{accountId}/vaccinationTypes](https://developers.propetware.com/apis/openapi-v1/vaccinations/createvaccinationtype.md): Create a new custom vaccination type for the account

### Update vaccination type

 - [PATCH /accounts/{accountId}/vaccinationTypes/{vaccinationTypeId}](https://developers.propetware.com/apis/openapi-v1/vaccinations/updatevaccinationtype.md): Update a custom vaccination type (account-owned types only)

### Delete vaccination type

 - [DELETE /accounts/{accountId}/vaccinationTypes/{vaccinationTypeId}](https://developers.propetware.com/apis/openapi-v1/vaccinations/deletevaccinationtype.md): Soft-delete a custom vaccination type (account-owned types only)

## Preventives

Operations related to pet preventive medication records

### List pet preventives

 - [GET /accounts/{accountId}/pets/{petId}/preventives](https://developers.propetware.com/apis/openapi-v1/preventives/listpetpreventives.md): Retrieve preventive records for a specific pet with expiration data

### List preventive types

 - [GET /accounts/{accountId}/preventiveTypes](https://developers.propetware.com/apis/openapi-v1/preventives/listpreventivetypes.md): Retrieve all preventive types configured for an account

## Products

Operations related to pricing rates, addons, retail products, classes, and adjustments

### List rates

 - [GET /accounts/{accountId}/products/rates](https://developers.propetware.com/apis/openapi-v1/products/listrates.md): Retrieve all pricing rates for an account

### Get rate

 - [GET /accounts/{accountId}/products/rates/{rateId}](https://developers.propetware.com/apis/openapi-v1/products/getrate.md): Retrieve a specific pricing rate with its value data and included addon IDs

### List addons

 - [GET /accounts/{accountId}/products/addons](https://developers.propetware.com/apis/openapi-v1/products/listaddons.md): Retrieve all pricing addons for an account (grooming, training, standalone)

### Get addon

 - [GET /accounts/{accountId}/products/addons/{addonId}](https://developers.propetware.com/apis/openapi-v1/products/getaddon.md): Retrieve a specific addon with its value data and included addon IDs

### List retail products

 - [GET /accounts/{accountId}/products/retail](https://developers.propetware.com/apis/openapi-v1/products/listretailproducts.md): Retrieve all retail products for an account

### Get retail product

 - [GET /accounts/{accountId}/products/retail/{productId}](https://developers.propetware.com/apis/openapi-v1/products/getretailproduct.md): Retrieve a specific retail product with its categories

### List classes

 - [GET /accounts/{accountId}/products/classes](https://developers.propetware.com/apis/openapi-v1/products/listclasses.md): Retrieve all class products for an account (subset of addons with serviceType=classes)

### Get class

 - [GET /accounts/{accountId}/products/classes/{addonId}](https://developers.propetware.com/apis/openapi-v1/products/getclass.md): Retrieve a specific class product with its value data

### List grooming services

 - [GET /accounts/{accountId}/products/grooming](https://developers.propetware.com/apis/openapi-v1/products/listgrooming.md): Retrieve all grooming service products for an account (subset of addons with serviceType=grooming)

### Get grooming service

 - [GET /accounts/{accountId}/products/grooming/{addonId}](https://developers.propetware.com/apis/openapi-v1/products/getgrooming.md): Retrieve a specific grooming service product with its value data

### List training services

 - [GET /accounts/{accountId}/products/training](https://developers.propetware.com/apis/openapi-v1/products/listtraining.md): Retrieve all training service products for an account (subset of addons with serviceType=training)

### Get training service

 - [GET /accounts/{accountId}/products/training/{addonId}](https://developers.propetware.com/apis/openapi-v1/products/gettraining.md): Retrieve a specific training service product with its value data

### List adjustments

 - [GET /accounts/{accountId}/products/adjustments](https://developers.propetware.com/apis/openapi-v1/products/listadjustments.md): Retrieve all pricing adjustments (discounts, vouchers, etc.) for an account

### Get adjustment

 - [GET /accounts/{accountId}/products/adjustments/{adjustmentId}](https://developers.propetware.com/apis/openapi-v1/products/getadjustment.md): Retrieve a specific pricing adjustment with its value data

## Webhooks

Manage webhook endpoints and view delivery history.

**Event delivery**
When a subscribed event occurs, Propetware POSTs a `WebhookEventEnvelope` JSON body to your URL. Every request includes three headers:
- `X-Propetware-Event` — the event type string (e.g. `customer.created`)
- `X-Propetware-Timestamp` — Unix timestamp of the delivery attempt (seconds)
- `X-Propetware-Signature` — `sha256=<hex>` HMAC-SHA256 signature

**Signature verification**
To verify a delivery, compute `HMAC-SHA256(webhookSecret, "<timestamp>.<rawBody>")` and compare the hex digest to the value of `X-Propetware-Signature` after stripping the `sha256=` prefix. Reject requests where the timestamp is more than 5 minutes old to prevent replay attacks.

**Retry policy**
Failed deliveries (non-2xx or network error) are retried up to 8 times with a 5-minute backoff, for up to 24 hours. 4xx responses are treated as permanent failures and are not retried.


### List webhooks

 - [GET /webhooks](https://developers.propetware.com/apis/openapi-v1/webhooks/listwebhooks.md): Retrieve all webhooks (requires webhooks:manage ability)

### Create webhook

 - [POST /webhooks](https://developers.propetware.com/apis/openapi-v1/webhooks/createwebhook.md): Create a new webhook (requires webhooks:manage ability)

### Update webhook

 - [PATCH /webhooks/{id}](https://developers.propetware.com/apis/openapi-v1/webhooks/updatewebhook.md): Update a webhook (requires webhooks:manage ability)

### Delete webhook

 - [DELETE /webhooks/{id}](https://developers.propetware.com/apis/openapi-v1/webhooks/deletewebhook.md): Delete a webhook (requires webhooks:manage ability)

### Get webhook deliveries

 - [GET /webhooks/{id}/deliveries](https://developers.propetware.com/apis/openapi-v1/webhooks/getwebhookdeliveries.md): Retrieve delivery history for a webhook (requires webhooks:manage ability)

### Test webhook

 - [POST /webhooks/{id}/test](https://developers.propetware.com/apis/openapi-v1/webhooks/testwebhook.md): Send a test delivery to a webhook (requires webhooks:manage ability)

