---
title: "Tworzy nową reklamację"
method: POST
path: "/complaints"
tags: ["Reklamacje"]
---

# Tworzy nową reklamację

`POST /complaints`

Rejestruje nową reklamację (RMA) w systemie na podstawie przekazanych danych adresowych, finansowych i źródłowych.

## Request body

- ComplaintRequest
  - `complaint_number` string — Własny numer reklamacji. Jeśli nie zostanie podany, system wygeneruje go automatycznie.
  - `date` string — Data zgłoszenia (Y-m-d H:i:s). W przypadku braku, zostanie użyta data bieżąca.
  - `status_id` integer — ID statusu reklamacji
  - `order_number` string — Numer powiązanego zamówienia
  - `shipment` string
  - `topic` string
  - `product` string
  - `user_email` string
  - `bankaccount` string
  - `description` string
  - `accept_date` string
  - `buyer_address` ComplaintAddressPayload, required
    - `name` string, required
    - `surname` string, required
    - `company` string, nullable
    - `nip` string, nullable
    - `city` string, required
    - `street` string
    - `home_number` string
    - `flat_number` string, nullable
    - `description` string, nullable
    - `postcode` string, required
    - `phone` string
    - `country` string — Kod ISO-3 kraju przeznaczony do mapowania na ID (np. POL)
  - `company` string, nullable
  - `source_id` integer
  - `refund_value` number
  - `refund_date` string
  - `refund_currency` string
  - `payment_id` integer
  - `tracking_number` string
  - `weight` number
  - `term` string
  - `close_date` string
  - `delivery_date` string
  - `shipment_address` ComplaintAddressPayload, required
    - `name` string, required
    - `surname` string, required
    - `company` string, nullable
    - `nip` string, nullable
    - `city` string, required
    - `street` string
    - `home_number` string
    - `flat_number` string, nullable
    - `description` string, nullable
    - `postcode` string, required
    - `phone` string
    - `country` string — Kod ISO-3 kraju przeznaczony do mapowania na ID (np. POL)
  - `additional_tracking_numbers` string
  - `allegro_order_id` string
  - `completed` integer — Status kompletności (0 lub 1)

## Response `200`

Pomyślnie utworzono reklamację.

- ComplaintResponseSuccess
  - `id` integer
  - `complaint_number` string

## Other responses

- `401` — Błąd autoryzacji

---

[API](https://skmtc.dev/sellasist/apis/sellasist-api.md) · [All operations](https://skmtc.dev/sellasist/apis/sellasist-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/sellasist/sellasist-api/revisions/821a1ff699fb/schema)
