# Businesses

A business is a tenant inside Lazy: one of your customers, with its own documents, transactions,
settings and usage. [Core concepts](https://developers.lazyinvoice.co.il/embedded/core-concepts/) explains how businesses fit with your
platform.

## Objects

- [Business object](https://developers.lazyinvoice.co.il/embedded/objects/businesses/): a business's IDs, name and creation time.
- [Tax info object](https://developers.lazyinvoice.co.il/embedded/objects/tax-info/): what Lazy knows about the business's taxes.

## Endpoints

| Endpoint                                                   | Request                                    |
| ---------------------------------------------------------- | ------------------------------------------ |
| [Create a business](https://developers.lazyinvoice.co.il/embedded/api/businesses/create/)      | `POST /v1/businesses`                      |
| [List businesses](https://developers.lazyinvoice.co.il/embedded/api/businesses/list/)          | `GET /v1/businesses`                       |
| [Get a business](https://developers.lazyinvoice.co.il/embedded/api/businesses/get/)            | `GET /v1/businesses/{biz_id}`              |
| [Update a business](https://developers.lazyinvoice.co.il/embedded/api/businesses/update/)      | `PATCH /v1/businesses/{biz_id}`            |
| [Delete a business](https://developers.lazyinvoice.co.il/embedded/api/businesses/delete/)      | `DELETE /v1/businesses/{biz_id}`           |
| [Get tax info](https://developers.lazyinvoice.co.il/embedded/api/tax-info/get/)                | `GET /v1/businesses/{biz_id}/tax-info`     |
| [Update tax info](https://developers.lazyinvoice.co.il/embedded/api/tax-info/update/)          | `PATCH /v1/businesses/{biz_id}/tax-info`   |

## A typical flow

1. When a customer signs up on your platform, [create a business](https://developers.lazyinvoice.co.il/embedded/api/businesses/create/)
   with your customer ID as `external_id`, and store the returned `biz_id`.
2. [Update its tax info](https://developers.lazyinvoice.co.il/embedded/api/tax-info/update/) with what you know about the customer.
3. When the customer leaves your platform, [delete the business](https://developers.lazyinvoice.co.il/embedded/api/businesses/delete/).
