---
title: "Create/Update container inquirys."
method: POST
path: "/container_inquiry/upsert"
tags: ["Containers|Container inquiry"]
---

# Create/Update container inquirys.

`POST /container_inquiry/upsert`

This method can be used to create and update container inquirys.

An effort is made to locate an existing container inquiry using the selected primary key. If found, it will be modified,
whereas if no container inquiry is found, a new one is created. If the `deleteMissing` flag is set to true, all container inquirys absent
from the request shall be purged. Please note that removed container inquirys may not be reinstated. You can enable the
`dryRun` setting to simulate the action without altering any live data.

## Request body

- StandardContainerInquiryUpsertRequest
  - `records` object[] — The records. This Parameter is optional.
    - `keyField` string — This parameter specifies the name of the unique key used to distinctly assign each dataset in the API. | Value | Description | |----------------|-----------------------------| | id | The internal container inquiry ID |
    - `data` ContainerInquiryUpsertRequestRecordData
      - `id` integer — The internal id of the container inquiry.
      - `name` string — The name of the container inquiry. (max. 128 characters)
      - `type` string — The container inquiry type. | type | | ---- | | CLEANING | container needs to be specified | | COLLECTION | container needs to be specified | | DELIVERY | container or container type needs to be specified | | FOUND | container or container type needs to be specified | | PICKUP | container needs to be specified | | REFILL | container needs to be specified | | REPLACEMENT | container needs to be specified |
      - `containerId` integer — The internal id of the container.
      - `containerTypeId` integer — The internal id of the container type.
      - `amount` integer — The amount of containers. Only for container type deliveries that allow the amount input.
      - `projectId` integer — The internal id of the assigned project. If no other address is set the address of this project will be used.
      - `street` string — The street for the inquiry. (max. 255 characters)
      - `zipCode` string — The zip code for the inquiry.
      - `city` string — The city for the inquiry. (max. 255 characters)
      - `countryCode` string — The country code for the inquiry.
      - `latLng` number[] — Represents a geo coordinate. An array of two double values, representing the latitude and longitude.
      - `contactPersonPhoneNumber` string — The phone number for the contact person. (max. 64 characters)
      - `contactPersonName` string — The name of the contact person. (max. 255 characters)
      - `targetDateTime` string — Represents a date and a time. (ISO 8601) ICU-Format: yyyy-MM-dd'T'HH:mm:ssxxx
      - `note` string — Additional notes.
  - `deleteMissing` boolean — Do you want to delete all tools missing from this request? This Parameter is optional. (Default: false)
  - `dryRun` boolean — Simulate the operation. (No records will be created or changed) This Parameter is optional.

## Response `200`

Success Response:

- StandardContainerInquiryUpsertResponse
  - `createdContainerInquiries` object[] — The created container inquiries.
    - `id` integer — The internal id of the container inquiry.
    - `name` string — The name of the container inquiry. (max. 128 characters)
    - `type` string — The container inquiry type. | type | | ---- | | CLEANING | container needs to be specified | | COLLECTION | container needs to be specified | | DELIVERY | container or container type needs to be specified | | FOUND | container or container type needs to be specified | | PICKUP | container needs to be specified | | REFILL | container needs to be specified | | REPLACEMENT | container needs to be specified |
    - `containerId` integer — The internal id of the container.
    - `containerTypeId` integer — The internal id of the container type.
    - `amount` integer — The amount of containers. Only for container type deliveries that allow the amount input.
    - `projectId` integer — The internal id of the assigned project. If no other address is set the address of this project will be used.
    - `street` string — The street for the inquiry. (max. 255 characters)
    - `zipCode` string — The zip code for the inquiry.
    - `city` string — The city for the inquiry. (max. 255 characters)
    - `countryCode` string — The country code for the inquiry.
    - `latLng` number[] — Represents a geo coordinate. An array of two double values, representing the latitude and longitude.
    - `contactPersonPhoneNumber` string — The phone number for the contact person. (max. 64 characters)
    - `contactPersonName` string — The name of the contact person. (max. 255 characters)
    - `targetDateTime` string — Represents a date and a time. (ISO 8601) ICU-Format: yyyy-MM-dd'T'HH:mm:ssxxx
    - `note` string — Additional notes.
  - `updatedContainerInquiries` object[] — The changed container inquiries.
    - `id` integer — The internal id of the container inquiry.
    - `name` string — The name of the container inquiry. (max. 128 characters)
    - `type` string — The container inquiry type. | type | | ---- | | CLEANING | container needs to be specified | | COLLECTION | container needs to be specified | | DELIVERY | container or container type needs to be specified | | FOUND | container or container type needs to be specified | | PICKUP | container needs to be specified | | REFILL | container needs to be specified | | REPLACEMENT | container needs to be specified |
    - `containerId` integer — The internal id of the container.
    - `containerTypeId` integer — The internal id of the container type.
    - `amount` integer — The amount of containers. Only for container type deliveries that allow the amount input.
    - `projectId` integer — The internal id of the assigned project. If no other address is set the address of this project will be used.
    - `street` string — The street for the inquiry. (max. 255 characters)
    - `zipCode` string — The zip code for the inquiry.
    - `city` string — The city for the inquiry. (max. 255 characters)
    - `countryCode` string — The country code for the inquiry.
    - `latLng` number[] — Represents a geo coordinate. An array of two double values, representing the latitude and longitude.
    - `contactPersonPhoneNumber` string — The phone number for the contact person. (max. 64 characters)
    - `contactPersonName` string — The name of the contact person. (max. 255 characters)
    - `targetDateTime` string — Represents a date and a time. (ISO 8601) ICU-Format: yyyy-MM-dd'T'HH:mm:ssxxx
    - `note` string — Additional notes.
  - `deletedContainerInquiries` object[] — The deleted container inquiries.
    - `id` integer — The internal id of the container inquiry.
    - `name` string — The name of the container inquiry. (max. 128 characters)
    - `type` string — The container inquiry type. | type | | ---- | | CLEANING | container needs to be specified | | COLLECTION | container needs to be specified | | DELIVERY | container or container type needs to be specified | | FOUND | container or container type needs to be specified | | PICKUP | container needs to be specified | | REFILL | container needs to be specified | | REPLACEMENT | container needs to be specified |
    - `containerId` integer — The internal id of the container.
    - `containerTypeId` integer — The internal id of the container type.
    - `amount` integer — The amount of containers. Only for container type deliveries that allow the amount input.
    - `projectId` integer — The internal id of the assigned project. If no other address is set the address of this project will be used.
    - `street` string — The street for the inquiry. (max. 255 characters)
    - `zipCode` string — The zip code for the inquiry.
    - `city` string — The city for the inquiry. (max. 255 characters)
    - `countryCode` string — The country code for the inquiry.
    - `latLng` number[] — Represents a geo coordinate. An array of two double values, representing the latitude and longitude.
    - `contactPersonPhoneNumber` string — The phone number for the contact person. (max. 64 characters)
    - `contactPersonName` string — The name of the contact person. (max. 255 characters)
    - `targetDateTime` string — Represents a date and a time. (ISO 8601) ICU-Format: yyyy-MM-dd'T'HH:mm:ssxxx
    - `note` string — Additional notes.

---

[API](https://skmtc.net/geocapture/apis/geocapture-api.md) · [All operations](https://skmtc.net/geocapture/apis/geocapture-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/geocapture/geocapture-api/versions/15839b24c497/schema)
