# Repzo API - Warehouse

OpenAPI specification for Repzo Warehouse endpoints.

**Version:** 1.0.0

## Overview

### Base URLs

- \*\*\*\*: `https://sv.api.repzo.me`

## Authentication

No authentication required.

## Endpoints

### `/warehouse`

#### GET /warehouse

**Summary:** Find warehouses

##### Parameters

| Name | Location | Type | Required | Description |
| ---- | -------- | ---- | -------- | ----------- |

| `params` | query | object | No | Query parameters for filtering warehouses |

##### Responses

**200** - A list of warehouses

Content-Type: `application/json`

---

#### POST /warehouse

**Summary:** Create a warehouse

##### Request Body

**Content Types:**

- `application/json`

##### Responses

**201** - Warehouse created

Content-Type: `application/json`

---

### `/warehouse/{id}`

#### GET /warehouse/{id}

**Summary:** Get a warehouse by ID

##### Parameters

| Name | Location | Type | Required | Description |
| ---- | -------- | ---- | -------- | ----------- |

| `id` | path | string | Yes | No description |

##### Responses

**200** - Warehouse details

Content-Type: `application/json`

---

#### PUT /warehouse/{id}

**Summary:** Update a warehouse

##### Parameters

| Name | Location | Type | Required | Description |
| ---- | -------- | ---- | -------- | ----------- |

| `id` | path | string | Yes | No description |

##### Request Body

**Content Types:**

- `application/json`

##### Responses

**200** - Warehouse updated

Content-Type: `application/json`

---

#### DELETE /warehouse/{id}

**Summary:** Remove a warehouse

##### Parameters

| Name | Location | Type | Required | Description |
| ---- | -------- | ---- | -------- | ----------- |

| `id` | path | string | Yes | No description |

##### Responses

**200** - Warehouse removed

Content-Type: `application/json`

---

## Data Models

### WarehouseFindResult

Result of finding warehouses

| Property | Type | Required | Description |
| -------- | ---- | -------- | ----------- |

| `data` | array | No | No description |

| `total_result` | number | No | Total number of warehouses |

| `current_count` | number | No | Count of warehouses in current page |

| `total_pages` | number | No | Total number of pages |

| `current_page` | number | No | Current page number |

| `per_page` | number | No | Number of warehouses per page |

| `first_page_url` | string | No | URL for the first page |

| `last_page_url` | string | No | URL for the last page |

| `next_page_url` | string | No | URL for the next page |

| `prev_page_url` | string | No | URL for the previous page |

| `path` | string | No | Base URL path |

### WarehouseSchema

Warehouse schema

| Property | Type | Required | Description |
| -------- | ---- | -------- | ----------- |

| `_id` | string | No | Unique identifier for the warehouse |

| `name` | string | No | Name of the warehouse |

| `location` | object | No | Geographic location of the warehouse |

| `disabled` | boolean | No | Whether the warehouse is disabled |

| `integration_meta` | object | No | Integration metadata |

| `company_namespace` | array | No | Company namespaces |

| `createdAt` | string | No | Creation timestamp |

| `updatedAt` | string | No | Last update timestamp |

| `__v` | number | No | Version number |

### WarehouseCreateBody

Body for creating a warehouse

| Property | Type | Required | Description |
| -------- | ---- | -------- | ----------- |

| `name` | string | Yes | Name of the warehouse |

| `location` | object | No | Geographic location of the warehouse |

| `disabled` | boolean | No | Whether the warehouse is disabled |

| `integration_meta` | object | No | Integration metadata |

| `company_namespace` | array | Yes | Company namespaces |

### WarehouseCreateResult

Result of creating a warehouse

### WarehouseGetResult

Result of getting a warehouse

### WarehouseUpdateBody

Body for updating a warehouse

| Property | Type | Required | Description |
| -------- | ---- | -------- | ----------- |

| `name` | string | No | Name of the warehouse |

| `location` | object | No | Geographic location of the warehouse |

| `disabled` | boolean | No | Whether the warehouse is disabled |

| `integration_meta` | object | No | Integration metadata |

| `company_namespace` | array | No | Company namespaces |

| `_id` | string | No | Unique identifier for the warehouse |

| `createdAt` | string | No | Creation timestamp |

| `updatedAt` | string | No | Last update timestamp |

| `__v` | number | No | Version number |

### WarehouseUpdateResult

Result of updating a warehouse

### WarehouseRemoveResult

Result of removing a warehouse

## TypeScript Usage

See [warehouse-examples.md](./warehouse-examples.md) for detailed TypeScript usage examples.
