---
title: "Batch updates cases"
method: POST
path: "/cases/batchUpdate"
tags: ["Case"]
---

# Batch updates cases

`POST /cases/batchUpdate`

## Request body

- CaseArray
  - `cases` Case[], required
    - `caseReference` object
      - `sourceId` string
      - `sourceUrl` string
      - `uploadIds` string[] — An array of UUIDs of uploads where this case was created or updated through bulk upload or automated ingestion.
      - `verificationStatus` 'UNVERIFIED' | 'VERIFIED' | 'EXCLUDED' — Whether the case document has been manually verified for correctness. For new cases, if this field isn't provided, a default value of UNVERIFIED will be used.
      - `additionalSources` object[]
        - `sourceUrl` string
    - `demographics` object
      - `gender` string
      - `ageRange` object
        - `start` number
        - `end` number
      - `ethnicity` string
      - `nationalities` string[]
      - `occupation` string
    - `location` Location
      - `query` string
      - `country` string — ISO-3166-2 code for a country.
      - `administrativeAreaLevel1` string
      - `administrativeAreaLevel2` string
      - `administrativeAreaLevel3` string
      - `place` string
      - `name` string
      - `geoResolution` string
      - `geometry` object
        - `latitude` number, required
        - `longitude` number, required
    - `events` object[] — An event with name "confirmed" must be specified. Other event names include onsetSymptoms, firstClinicalConsultation, selfIsolation, hospitalAdmission, icuAdmission, and outcome.
      - `name` string
      - `dateRange` DateRange
        - `start` union
          - string
          - object
          - number
        - `end` union
          - string
          - object
          - number
      - `value` string
    - `symptoms` object
      - `status` string
      - `values` string[]
    - `preexistingConditions` object
      - `hasPreexistingConditions` boolean
      - `values` string[]
    - `transmission` object
      - `routes` string[]
      - `places` string[]
      - `linkedCaseIds` string[]
    - `travelHistory` object
      - `traveledPrior30Days` boolean
      - `travel` object[]
        - `dateRange` DateRange
          - `start` union
            - string
            - object
            - number
          - `end` union
            - string
            - object
            - number
        - `location` FuzzyLocation — A geo location that can be unspecific. It may not be geocoded if it lacks information.
          - `country` string — ISO-3166-2 code for a country.
          - `administrativeAreaLevel1` string — First administrative subdivision of a country
          - `administrativeAreaLevel2` string — Second administrative subdivision of a country
          - `administrativeAreaLevel3` string — Third administrative subdivision of a country
          - `place` string — Name of the place this location refers to
          - `name` string — Full name of the location
          - `geoResolution` 'undefined' | 'Point' | 'Admin3' | 'Admin2' | 'Admin1' | 'Country' — How granular the location is
          - `geometry` object
            - `latitude` number
            - `longitude` number
        - `purpose` string
        - `methods` string[]
    - `variant` object
      - `name` string
    - `vaccines` Vaccine[] — A list of vaccines
      - `name` string — The name of the vaccine administered
      - `batch` string — The batch ID of the vaccine dose administered
      - `date` union
        - string
        - object
        - number
      - `sideEffects` SymptomArray
        - `symptoms` string[]
    - `genomeSequences` object[]
      - `sampleCollectionDate` union
        - string
        - object
        - number
      - `repositoryUrl` string
      - `sequenceId` string
      - `sequenceName` string
      - `sequenceLength` integer
    - `pathogens` object[]
      - `name` string
      - `id` integer
    - `revisionMetadata` object
      - `revisionNumber` integer, required
      - `creationMetadata` EditMetadata
        - `curator` string
        - `date` union
          - string
          - object
          - number
        - `notes` string
      - `editMetadata` EditMetadata
        - `curator` string
        - `date` union
          - string
          - object
          - number
        - `notes` string
    - `SGTF` 'NA' | '0' | '1'

## Response `200`

OK

- BatchUpdateResponse — Response to batch update cases API requests
  - `numModified` number, required

## Other responses

- `400` — Malformed request
- `422` — Unprocessable entity
- `500` — Internal server error

---

[API](https://skmtc.net/globaldothealth/apis/global-health-data-service.md) · [All operations](https://skmtc.net/globaldothealth/apis/global-health-data-service/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/globaldothealth/global-health-data-service/revisions/886deae8a6f9/schema)
