Referencja API

Dostęp produkcyjny zamknięty · 37 operacji

Edytuj ogłoszenie

PATCH/api/v1/listings/{id}

Zapisane ogłoszenie.

Pominięte pola pozostają bez zmian. Przy zmianie images lub equipment podaj pełną nową tablicę. Pobierz aktualny ETag przed zapisem.

Wymagany zakres listings:write

Przejdź do przykładu

Parametry

NazwaMiejsceTypWymaganyOpis
idpathstringTakmin. znaków 1 · maks. znaków 120
If-MatchheaderstringTakOstatni ETag oferty zwrócony przez API.
Idempotency-KeyheaderstringTakUUID żądania. Ponów z tym samym kluczem w ciągu 7 dni. format uuid

Treść żądania

Schemat UpdateListingInput
NazwaTypWymaganyOpis
titlestringNiemaks. znaków 100
shortDescriptionstringNiemaks. znaków 80
descriptionstringNiemaks. znaków 16000
priceintegerNieminimum 0 · maksimum 1000000000
makestringNiemaks. znaków 120
modelstringNiemaks. znaków 120
generationstring | nullNie—
makeIdstringNiemaks. znaków 180
modelIdstringNiemaks. znaków 300
generationIdstringNiemaks. znaków 180
yearinteger | nullNie—
locationstringNie—
voivodeshipstringNiemaks. znaków 80
mileageinteger | nullNie—
fuelType"petrol" | "diesel" | "electric" | "hybrid" | "lpg" | nullNie—
bodyTypestringNiemaks. znaków 80
gearboxstringNiemaks. znaków 80
driveTypestringNiemaks. znaków 80
powerintegerNieminimum 1 · maksimum 5000
engineCcintegerNieminimum 0 · maksimum 30000
colorstringNiemaks. znaków 50
condition"new" | "used"Nie"new" | "used"
noAccidentbooleanNie—
firstOwnerbooleanNie—
vatInvoicebooleanNie—
negotiablebooleanNie—
contactNamestringNiemaks. znaków 120
contactPhonestringNiemaks. znaków 40
dealerLocationIdstring | nullNie—
priceTypestringNiemaks. znaków 40
equipmentstring[]NiePełna docelowa lista opcji. Pusta tablica czyści opcje, a pominięcie pola zachowuje dotychczasowe. maks. elementów 300
imagesstring | string[]NiePo pominięciu pola zdjęcia pozostają bez zmian. maks. elementów 18
detailsobjectNie—
latnumberNieminimum -90 · maksimum 90
lngnumberNieminimum -180 · maksimum 180
listingTypeValuestringNiemin. znaków 1 · maks. znaków 100
formContractVersion2Nie—
JSON Schema
{
  "$ref": "#/components/schemas/UpdateListingInput"
}

Odpowiedzi

200 Zapisane ogłoszenie.
ETag
Wersja do nagłówka If-Match.
application/json
Schemat MutationReceipt
NazwaTypWymaganyOpis
idstringTak—
status"draft" | "payment_required" | "active" | "expired" | "sold"Tak—
publicationState"public" | "pending" | "hidden"Tak—
updatedAtstringTakformat date-time
publicPathstring | nullTak—
paymentPathstringNie—
paymentPaymentReceiptNie—
archiveFeedbackobjectNie—
JSON Schema
{
  "$ref": "#/components/schemas/MutationReceipt"
}
409 Błąd przetwarzania żądania.
application/json
Schemat object
NazwaTypWymaganyOpis
codestringTak—
messagestringTak—
requestIdstringTak—
issuesobject[]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/json
Schemat object
NazwaTypWymaganyOpis
codestringTak—
messagestringTak—
requestIdstringTak—
issuesobject[]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/json
Schemat object
NazwaTypWymaganyOpis
codestringTak—
messagestringTak—
requestIdstringTak—
issuesobject[]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/json
Schemat object
NazwaTypWymaganyOpis
codestringTak—
messagestringTak—
requestIdstringTak—
issuesobject[]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/json
Schemat object
NazwaTypWymaganyOpis
codestringTak—
messagestringTak—
requestIdstringTak—
issuesobject[]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.

Obsługa błędów i limitów ↗

Powiązane schematy

UpdateListingInput
{
  "type": "object",
  "properties": {
    "title": {
      "type": "string",
      "maxLength": 100,
      "pattern": "^[^\\p{Cc}\\p{Cf}]*$"
    },
    "shortDescription": {
      "type": "string",
      "maxLength": 80
    },
    "description": {
      "type": "string",
      "maxLength": 16000,
      "pattern": "^[^\\u0000-\\u0008\\u000B\\u000C\\u000E-\\u001F\\u007F]*$"
    },
    "price": {
      "type": "integer",
      "minimum": 0,
      "maximum": 1000000000
    },
    "make": {
      "type": "string",
      "maxLength": 120
    },
    "model": {
      "type": "string",
      "maxLength": 120
    },
    "generation": {
      "anyOf": [
        {
          "type": "string",
          "maxLength": 80
        },
        {
          "type": "null"
        }
      ]
    },
    "makeId": {
      "type": "string",
      "maxLength": 180
    },
    "modelId": {
      "type": "string",
      "maxLength": 300
    },
    "generationId": {
      "type": "string",
      "maxLength": 180
    },
    "year": {
      "anyOf": [
        {
          "type": "integer",
          "minimum": 1900,
          "maximum": 2027
        },
        {
          "type": "null"
        }
      ]
    },
    "location": {
      "type": "string"
    },
    "voivodeship": {
      "type": "string",
      "maxLength": 80
    },
    "mileage": {
      "anyOf": [
        {
          "type": "integer",
          "minimum": 0,
          "maximum": 10000000
        },
        {
          "type": "null"
        }
      ]
    },
    "fuelType": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "petrol",
            "diesel",
            "electric",
            "hybrid",
            "lpg"
          ]
        },
        {
          "type": "null"
        }
      ]
    },
    "bodyType": {
      "type": "string",
      "maxLength": 80
    },
    "gearbox": {
      "type": "string",
      "maxLength": 80
    },
    "driveType": {
      "type": "string",
      "maxLength": 80
    },
    "power": {
      "type": "integer",
      "minimum": 1,
      "maximum": 5000
    },
    "engineCc": {
      "type": "integer",
      "minimum": 0,
      "maximum": 30000
    },
    "color": {
      "type": "string",
      "maxLength": 50
    },
    "condition": {
      "type": "string",
      "enum": [
        "new",
        "used"
      ]
    },
    "noAccident": {
      "type": "boolean"
    },
    "firstOwner": {
      "type": "boolean"
    },
    "vatInvoice": {
      "type": "boolean"
    },
    "negotiable": {
      "type": "boolean"
    },
    "contactName": {
      "type": "string",
      "maxLength": 120
    },
    "contactPhone": {
      "type": "string",
      "maxLength": 40
    },
    "dealerLocationId": {
      "anyOf": [
        {
          "type": "string",
          "minLength": 1,
          "maxLength": 120
        },
        {
          "type": "null"
        }
      ]
    },
    "priceType": {
      "type": "string",
      "maxLength": 40
    },
    "equipment": {
      "maxItems": 300,
      "type": "array",
      "items": {
        "type": "string",
        "maxLength": 120
      },
      "description": "Pełna docelowa lista opcji. Pusta tablica czyści opcje, a pominięcie pola zachowuje dotychczasowe."
    },
    "images": {
      "maxItems": 18,
      "type": "array",
      "items": {
        "anyOf": [
          {
            "type": "string",
            "pattern": "^[a-zA-Z0-9][a-zA-Z0-9._-]{0,119}$"
          },
          {
            "type": "string",
            "pattern": "^existing:[a-f0-9]{64}$"
          }
        ]
      },
      "description": "Po pominięciu pola zdjęcia pozostają bez zmian."
    },
    "details": {
      "type": "object",
      "properties": {
        "vin": {
          "type": "string",
          "minLength": 1,
          "maxLength": 17,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "serialNumber": {
          "type": "string",
          "minLength": 1,
          "maxLength": 64,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "registrationNumber": {
          "type": "string",
          "minLength": 1,
          "maxLength": 32,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "firstRegistrationDate": {
          "type": "string",
          "format": "date",
          "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
        },
        "lifetimeHours": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "trailerAxleCount": {
          "type": "integer",
          "minimum": 0,
          "maximum": 8
        },
        "trailerCargo": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "trailerGrossWeightKg": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "trailerPayloadKg": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "camperBedLayout": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "camperSleepingPlaces": {
          "type": "integer",
          "minimum": 0,
          "maximum": 50
        },
        "camperTravelSeats": {
          "type": "integer",
          "minimum": 0,
          "maximum": 100
        },
        "camperBase": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "camperGvwKg": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "camperKitchen": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "camperBathroom": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "propulsion": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "maxExcavatingDepthMm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "maxExcavatingCapacityM3": {
          "type": "number",
          "minimum": 0,
          "maximum": 10000
        },
        "maxLiftingWeightKg": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "maxLiftingHeightMm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "offHighway": {
          "type": "boolean"
        },
        "refrigeratorUnit": {
          "type": "boolean"
        },
        "partMainCategory": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partSubCategory": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partCategoryPath": {
          "maxItems": 10,
          "type": "array",
          "items": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
          }
        },
        "partProducer": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partProducerCustom": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partCondition": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partStockQuantity": {
          "type": "integer",
          "minimum": 0,
          "maximum": 100000
        },
        "partVehicleTypes": {
          "maxItems": 24,
          "type": "array",
          "items": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
          }
        },
        "partCompatibilityVehicles": {
          "maxItems": 80,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "scope": {
                "type": "string",
                "enum": [
                  "passenger",
                  "delivery",
                  "truck",
                  "motorcycle",
                  "camper",
                  "trailer",
                  "agriculture",
                  "construction"
                ]
              },
              "make": {
                "type": "string",
                "minLength": 1,
                "maxLength": 160,
                "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
              },
              "model": {
                "type": "string",
                "minLength": 1,
                "maxLength": 160,
                "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
              },
              "generation": {
                "type": "string",
                "minLength": 1,
                "maxLength": 160,
                "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
              },
              "makeId": {
                "type": "string",
                "minLength": 1,
                "maxLength": 180,
                "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
              },
              "modelId": {
                "type": "string",
                "minLength": 1,
                "maxLength": 300,
                "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
              },
              "generationId": {
                "type": "string",
                "minLength": 1,
                "maxLength": 180,
                "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
              },
              "customMake": {
                "type": "string",
                "minLength": 1,
                "maxLength": 120,
                "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
              },
              "customModel": {
                "type": "string",
                "minLength": 1,
                "maxLength": 120,
                "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
              },
              "yearFrom": {
                "type": "integer",
                "minimum": 0,
                "maximum": 2200
              },
              "yearTo": {
                "type": "integer",
                "minimum": 0,
                "maximum": 2200
              },
              "engineVersion": {
                "type": "string",
                "minLength": 1,
                "maxLength": 160,
                "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
              }
            },
            "additionalProperties": false
          }
        },
        "partYearFrom": {
          "type": "integer",
          "minimum": 0,
          "maximum": 2200
        },
        "partYearTo": {
          "type": "integer",
          "minimum": 0,
          "maximum": 2200
        },
        "partTireWidth": {
          "anyOf": [
            {
              "type": "integer",
              "minimum": 0,
              "maximum": 500
            },
            {
              "type": "string",
              "pattern": "^\\d{2,3}$"
            }
          ]
        },
        "partTireProfile": {
          "anyOf": [
            {
              "type": "integer",
              "minimum": 0,
              "maximum": 100
            },
            {
              "type": "string",
              "pattern": "^\\d{1,3}$"
            }
          ]
        },
        "partRimSize": {
          "anyOf": [
            {
              "type": "number",
              "minimum": 1,
              "maximum": 100
            },
            {
              "type": "string",
              "pattern": "^\\d{1,2}(?:[.,]\\d{1,2})?$"
            }
          ]
        },
        "partTireType": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partRimsType": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partDelivery": {
          "type": "object",
          "properties": {
            "dpdEnabled": {
              "type": "boolean"
            },
            "dpdCost": {
              "type": "number",
              "minimum": 0,
              "maximum": 100000
            },
            "inpostEnabled": {
              "type": "boolean"
            },
            "inpostCost": {
              "type": "number",
              "minimum": 0,
              "maximum": 100000
            },
            "postEnabled": {
              "type": "boolean"
            },
            "postCost": {
              "type": "number",
              "minimum": 0,
              "maximum": 100000
            },
            "pickupEnabled": {
              "type": "boolean"
            }
          },
          "additionalProperties": false
        },
        "partOeNumbers": {
          "maxItems": 30,
          "type": "array",
          "items": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
          }
        },
        "partQuantityLabel": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partEngineVersion": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partTireBrand": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partSpeedIndex": {
          "type": "string",
          "minLength": 1,
          "maxLength": 12,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partRollingResistance": {
          "type": "string",
          "minLength": 1,
          "maxLength": 12,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partWetGrip": {
          "type": "string",
          "minLength": 1,
          "maxLength": 12,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partExternalNoiseDb": {
          "type": "integer",
          "minimum": 0,
          "maximum": 150
        },
        "partInstallationPositions": {
          "maxItems": 12,
          "type": "array",
          "items": {
            "type": "string",
            "minLength": 1,
            "maxLength": 160,
            "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
          }
        },
        "partSteeringSide": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partAdditionalCompatibility": {
          "type": "string",
          "minLength": 1,
          "maxLength": 1000,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partDeliveryTime": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partReturnPolicy": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partSalesDocument": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "partCustomName": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "offerMode": {
          "type": "string",
          "enum": [
            "sale",
            "rent"
          ]
        },
        "financingAvailable": {
          "type": "boolean"
        },
        "leasingAvailable": {
          "type": "boolean"
        },
        "exchangePossible": {
          "type": "boolean"
        },
        "showPhone": {
          "type": "boolean"
        },
        "mapPinnedManually": {
          "type": "boolean"
        },
        "damaged": {
          "type": "boolean"
        },
        "rightHandDrive": {
          "type": "boolean"
        },
        "doubleRearWheels": {
          "type": "boolean"
        },
        "engineCode": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "seats": {
          "anyOf": [
            {
              "type": "integer",
              "minimum": 0,
              "maximum": 120
            },
            {
              "type": "string",
              "minLength": 1,
              "maxLength": 12,
              "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
            }
          ]
        },
        "doors": {
          "anyOf": [
            {
              "type": "integer",
              "minimum": 0,
              "maximum": 30
            },
            {
              "type": "string",
              "minLength": 1,
              "maxLength": 12,
              "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
            }
          ]
        },
        "colorType": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "upholsteryMaterial": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "upholsteryColor": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "motorcycleLicenseCategory": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "truckCabinType": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "dpfStatus": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "accidentHistory": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "serviceHistory": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "ownerCount": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "firstRegistrationCountry": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "registrationInPolandDate": {
          "type": "string",
          "format": "date",
          "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
        },
        "technicalInspectionUntil": {
          "type": "string",
          "format": "date",
          "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
        },
        "warrantyUntil": {
          "type": "string",
          "format": "date",
          "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
        },
        "makerWarrantyUntilKm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 10000000
        },
        "lengthMm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "widthMm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "heightMm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "wheelbaseMm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "curbWeightKg": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "camperInteriorLengthMm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "camperInteriorWidthMm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "camperInteriorHeightMm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "camperTotalHeightMm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "camperFreshWaterL": {
          "type": "integer",
          "minimum": 0,
          "maximum": 10000
        },
        "camperGreyWaterL": {
          "type": "integer",
          "minimum": 0,
          "maximum": 10000
        },
        "camperLpgTankL": {
          "type": "integer",
          "minimum": 0,
          "maximum": 10000
        },
        "powerKw": {
          "type": "integer",
          "minimum": 0,
          "maximum": 10000
        },
        "topSpeedKmh": {
          "type": "integer",
          "minimum": 0,
          "maximum": 2000
        },
        "torqueNm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 100000
        },
        "co2Emission": {
          "type": "integer",
          "minimum": 0,
          "maximum": 10000
        },
        "euroStandard": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "fuelConsumptionCity": {
          "type": "number",
          "minimum": 0,
          "maximum": 1000
        },
        "fuelConsumptionHighway": {
          "type": "number",
          "minimum": 0,
          "maximum": 1000
        },
        "fuelConsumptionCombined": {
          "type": "number",
          "minimum": 0,
          "maximum": 1000
        },
        "tankCapacityL": {
          "type": "integer",
          "minimum": 0,
          "maximum": 100000
        },
        "trunkCapacityL": {
          "type": "integer",
          "minimum": 0,
          "maximum": 100000
        },
        "acceleration0100": {
          "type": "number",
          "minimum": 0,
          "maximum": 120
        },
        "batteryRangeKm": {
          "type": "integer",
          "minimum": 0,
          "maximum": 10000
        },
        "chargerPowerKw": {
          "type": "integer",
          "minimum": 0,
          "maximum": 10000
        },
        "maxChargingPowerKw": {
          "type": "number",
          "minimum": 0,
          "maximum": 10000
        },
        "chargingTime80Min": {
          "type": "integer",
          "minimum": 0,
          "maximum": 100000
        },
        "chargingTime100Min": {
          "type": "integer",
          "minimum": 0,
          "maximum": 100000
        },
        "chargingTimeHomeMin": {
          "type": "integer",
          "minimum": 0,
          "maximum": 100000
        },
        "chargingConnectorType": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "chargingCurrentType": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "batteryCapacityKwh": {
          "type": "number",
          "minimum": 0,
          "maximum": 100000
        },
        "batteryType": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "batteryCondition": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "batteryCount": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000
        },
        "batteryCycleCount": {
          "type": "integer",
          "minimum": 0,
          "maximum": 1000000
        },
        "electricPowerPeakKw": {
          "type": "integer",
          "minimum": 0,
          "maximum": 10000
        },
        "evBattery": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "evCable": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "evFastCharge": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "evRegen": {
          "type": "string",
          "minLength": 1,
          "maxLength": 160,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "customMake": {
          "type": "string",
          "minLength": 1,
          "maxLength": 120,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        },
        "customModel": {
          "type": "string",
          "minLength": 1,
          "maxLength": 120,
          "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
        }
      },
      "additionalProperties": false
    },
    "lat": {
      "type": "number",
      "minimum": -90,
      "maximum": 90
    },
    "lng": {
      "type": "number",
      "minimum": -180,
      "maximum": 180
    },
    "listingTypeValue": {
      "type": "string",
      "minLength": 1,
      "maxLength": 100,
      "pattern": "^[^\\p{Cc}\\p{Cf}]+$"
    },
    "formContractVersion": {
      "type": "number",
      "const": 2
    }
  },
  "additionalProperties": false,
  "description": "Szkic może być niekompletny. Aktywne ogłoszenie i szkic z płatnością obowiązują pełne reguły publikacji."
}
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"
    }
  }
}