# Hasaki — Wrapped API

> **You are on:** `https://api.paywithlocus.com/api` | [llms.txt](https://paywithlocus.com/llms.txt) | [docs](https://docs.paywithlocus.com)
>
> Locus runs on multiple environments -- make sure every URL you call matches your expected environment.
> | Environment | Landing | API | Docs |
> |---|---|---|---|
> | Production | paywithlocus.com | api.paywithlocus.com | docs.paywithlocus.com |
> | Beta | beta.paywithlocus.com | api.beta.paywithlocus.com | docs.paywithlocus.com |
> | Stage | stage.paywithlocus.com | api.stage.paywithlocus.com | docs.paywithlocus.com |
>
> If the API URL above doesn't match your expected environment, re-fetch this file from the correct domain.

> Search and browse products from Hasaki.vn's beauty and skincare catalog, including detailed product information, customer reviews, brand listings, and special flash deals. Discover new arrivals, best sellers, and get autocomplete suggestions to find exactly what you're looking for.

**Category:** E-commerce | **Website:** [hasaki.vn/](https://hasaki.vn/) | **Docs:** [parse.bot/marketplace/e5fe21cb-7f91-4855-9155-6c7d2eac6c89/hasaki-vn-api](https://parse.bot/marketplace/e5fe21cb-7f91-4855-9155-6c7d2eac6c89/hasaki-vn-api)

Pay-per-use API proxy. Each call is automatically billed to your wallet in USDC.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### get_best_sellers

Retrieve best-selling products sorted by sales volume across all categories or within a specific category. Returns the same product structure as category listings with filter options.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | integer | No | Page number for pagination. |
| `size` | integer | No | Number of results per page. |
| `slug` | string | No | Category slug to filter best sellers by category (e.g. 'cham-soc-da-mat-c4'). Omitting returns all categories. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/get_best_sellers \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"page":"<integer>","size":"<integer>","slug":"<string>"}'
```

### get_brand_products

Retrieve paginated products for a specific brand by its URL slug. Returns brand info, filter options, and products sorted by the chosen order.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | integer | No | Page number for pagination. |
| `size` | integer | No | Number of results per page. |
| `slug` | string | Yes | Brand slug from the URL path (e.g. 'cerave', 'la-roche-posay', 'cocoon'). |
| `sort` | string | No | Sort order for products. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/get_brand_products \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"page":"<integer>","size":"<integer>","slug":"<string>","sort":"<string>"}'
```

### get_brands_list

Retrieve the full list of all brands available on Hasaki, organized alphabetically by first letter. Each brand includes id, name, URL, logo image, and cover image.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/get_brands_list \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_categories

Retrieve the full hierarchical category tree including nested subcategories, navigation menu links, and banners. Categories are organized in a multi-level tree with URL paths suitable for use with get_category_products.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/get_categories \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### get_category_products

Retrieve paginated products from a specific category by its URL slug. Supports sorting by position (newest), top sales, or price. Returns filter options and brand highlights for the category.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | integer | No | Page number for pagination. |
| `size` | integer | No | Number of results per page. |
| `slug` | string | Yes | Category slug from the URL path (e.g. 'cham-soc-da-mat-c4', 'chong-nang-da-mat-c11'). |
| `sort` | string | No | Sort order for products. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/get_category_products \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"page":"<integer>","size":"<integer>","slug":"<string>","sort":"<string>"}'
```

### get_flash_deals

Retrieve current Flash Deal (Hasaki Deals) products with discount information and countdown timers. Deals rotate by time period key.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `key` | string | No | Flash deal period key (e.g. 'deal08'). |
| `page` | integer | No | Page number for pagination. |
| `size` | integer | No | Number of results per page. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/get_flash_deals \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"key":"<string>","page":"<integer>","size":"<integer>"}'
```

### get_new_arrivals

Retrieve new arrival products sorted by newest first across all categories or within a specific category. Returns the same product structure as category listings with filter options.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | integer | No | Page number for pagination. |
| `size` | integer | No | Number of results per page. |
| `slug` | string | No | Category slug to filter new arrivals by category (e.g. 'cham-soc-da-mat-c4'). Omitting returns all categories. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/get_new_arrivals \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"page":"<integer>","size":"<integer>","slug":"<string>"}'
```

### get_product_detail

Fetch full product detail including descriptions, image gallery, variants, pricing, deal info, promotions, and related products. Returns structured content blocks.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `product_id` | string | Yes | Numeric product ID (e.g. '86167', '102959'). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/get_product_detail \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"product_id":"<string>"}'
```

### get_product_qa

Retrieve paginated product Q&A (Hỏi đáp) section including customer questions and staff replies. Each comment may have sub_comments containing the official response.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | integer | No | Page number for pagination. |
| `product_id` | string | Yes | Numeric product ID (e.g. '86167'). |
| `size` | integer | No | Number of Q&A items per page. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/get_product_qa \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"page":"<integer>","product_id":"<string>","size":"<integer>"}'
```

### get_product_reviews

Retrieve paginated customer reviews for a product. Includes rating distribution (star breakdown), sort options, and individual reviews with user info, content, images, and staff responses.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `filter` | string | No | Filter reviews by star rating or image presence. |
| `page` | integer | No | Page number for pagination. |
| `product_id` | string | Yes | Numeric product ID (e.g. '86167'). |
| `size` | integer | No | Number of reviews per page. |
| `sort` | string | No | Sort order for reviews. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/get_product_reviews \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"filter":"<string>","page":"<integer>","product_id":"<string>","size":"<integer>","sort":"<string>"}'
```

### get_search_autocomplete

Retrieve search autocomplete suggestions for a partial query. Returns keyword matches, category suggestions, product previews with prices, and brand matches.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `query` | string | Yes | Partial search query (e.g. 'kem', 'serum'). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/get_search_autocomplete \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"query":"<string>"}'
```

### search_products

Full-text search over Hasaki's product catalog by keyword. Returns paginated product results sorted by relevance/sales with metadata including total count and available sort/filter options. Each product includes pricing, brand, rating, and deal info.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `page` | integer | No | Page number for pagination. |
| `query` | string | Yes | Search keyword (e.g. 'kem chống nắng', 'serum vitamin c'). |
| `size` | integer | No | Number of results per page. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-hasaki-vn-api-e5fe21cb/search_products \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"page":"<integer>","query":"<string>","size":"<integer>"}'
```
