Skopiuj ogłoszenie do szkicu
POST
/api/v1/listings/{id}/duplicateNowy szkic skopiowany z ogłoszenia.
Kopia ma nowe ID, darmowy pakiet i puste zdjęcia. Usuń zależność od danych identyfikacyjnych pojazdu, przebiegu i płatności starego ogłoszenia.
Wymagany zakres listings:write
Parametry
| Nazwa | Miejsce | Typ | Wymagany | Opis |
|---|---|---|---|---|
id | path | string | Tak | min. znaków 1 · maks. znaków 120 |
If-Match | header | string | Tak | Ostatni ETag oferty zwrócony przez API. |
Idempotency-Key | header | string | Tak | UUID żądania. Ponów z tym samym kluczem w ciągu 7 dni. format uuid |
Treść żądania
Schemat DuplicateInput
JSON Schema
{
"$ref": "#/components/schemas/DuplicateInput"
}Odpowiedzi
201 Nowy szkic skopiowany z ogłoszenia.ETag- Wersja do nagłówka If-Match.
Location- Ścieżka nowego szkicu.
application/jsonSchemat MutationReceipt
| Nazwa | Typ | Wymagany | Opis |
|---|---|---|---|
id | string | Tak | — |
status | "draft" | "payment_required" | "active" | "expired" | "sold" | Tak | — |
publicationState | "public" | "pending" | "hidden" | Tak | — |
updatedAt | string | Tak | format date-time |
publicPath | string | null | Tak | — |
paymentPath | string | Nie | — |
payment | PaymentReceipt | Nie | — |
archiveFeedback | object | Nie | — |
JSON Schema
{
"$ref": "#/components/schemas/MutationReceipt"
}409 Błąd przetwarzania żądania.application/jsonSchemat object
| Nazwa | Typ | Wymagany | Opis |
|---|---|---|---|
code | string | Tak | — |
message | string | Tak | — |
requestId | string | Tak | — |
issues | object[] | Nie | — |
JSON Schema
{
"type": "object",
"required": [
"code",
"message",
"requestId"
],
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"requestId": {
"type": "string"
},
"issues": {
"type": "array",
"items": {
"type": "object"
}
}
}
}412 Błąd przetwarzania żądania.application/jsonSchemat object
| Nazwa | Typ | Wymagany | Opis |
|---|---|---|---|
code | string | Tak | — |
message | string | Tak | — |
requestId | string | Tak | — |
issues | object[] | Nie | — |
JSON Schema
{
"type": "object",
"required": [
"code",
"message",
"requestId"
],
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"requestId": {
"type": "string"
},
"issues": {
"type": "array",
"items": {
"type": "object"
}
}
}
}422 Błąd przetwarzania żądania.application/jsonSchemat object
| Nazwa | Typ | Wymagany | Opis |
|---|---|---|---|
code | string | Tak | — |
message | string | Tak | — |
requestId | string | Tak | — |
issues | object[] | Nie | — |
JSON Schema
{
"type": "object",
"required": [
"code",
"message",
"requestId"
],
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"requestId": {
"type": "string"
},
"issues": {
"type": "array",
"items": {
"type": "object"
}
}
}
}428 Błąd przetwarzania żądania.application/jsonSchemat object
| Nazwa | Typ | Wymagany | Opis |
|---|---|---|---|
code | string | Tak | — |
message | string | Tak | — |
requestId | string | Tak | — |
issues | object[] | Nie | — |
JSON Schema
{
"type": "object",
"required": [
"code",
"message",
"requestId"
],
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"requestId": {
"type": "string"
},
"issues": {
"type": "array",
"items": {
"type": "object"
}
}
}
}Pozostałe błędy API Błąd przetwarzania żądania.application/jsonSchemat object
| Nazwa | Typ | Wymagany | Opis |
|---|---|---|---|
code | string | Tak | — |
message | string | Tak | — |
requestId | string | Tak | — |
issues | object[] | Nie | — |
JSON Schema
{
"type": "object",
"required": [
"code",
"message",
"requestId"
],
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
},
"requestId": {
"type": "string"
},
"issues": {
"type": "array",
"items": {
"type": "object"
}
}
}
}401 Brak prawidłowego klucza API.403 Brak zakresu wymaganego przez operację lub żądanie bez HTTPS na produkcji.429 Przekroczono limit zapytań. Sprawdź Retry-After.503 Dostęp jest zamknięty lub usługa jest chwilowo niedostępna. Sprawdź code.Powiązane schematy
DuplicateInput
{
"type": "object",
"properties": {},
"additionalProperties": false
}MutationReceipt
{
"type": "object",
"required": [
"id",
"status",
"publicationState",
"updatedAt",
"publicPath"
],
"properties": {
"id": {
"type": "string"
},
"status": {
"enum": [
"draft",
"payment_required",
"active",
"expired",
"sold"
]
},
"publicationState": {
"enum": [
"public",
"pending",
"hidden"
]
},
"updatedAt": {
"type": "string",
"format": "date-time"
},
"publicPath": {
"type": [
"string",
"null"
]
},
"paymentPath": {
"type": "string"
},
"payment": {
"$ref": "#/components/schemas/PaymentReceipt"
},
"archiveFeedback": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"outcome": {
"enum": [
"sold",
"not_sold",
"other"
]
},
"recommendationScore": {
"type": [
"integer",
"null"
],
"minimum": 1,
"maximum": 10
},
"updatedAt": {
"type": "string",
"format": "date-time"
}
},
"required": [
"id",
"outcome",
"recommendationScore",
"updatedAt"
]
}
}
}PaymentReceipt
{
"type": "object",
"required": [
"id",
"amountCents",
"currency",
"status"
],
"properties": {
"id": {
"type": "string"
},
"amountCents": {
"type": "integer",
"minimum": 1
},
"currency": {
"type": "string"
},
"status": {
"type": "string"
}
}
}