---
title: Bulk Add / Update Well Data
slug: bulk-add-update-well-data
docTags: 
createdAt: 2023-05-03T20:15:30.000Z
---

{
  "id": "UXtm8sToXo8qZcdkesQ_T",
  "type": "api-oas-v2",
  "data": {
    "method": "POST",
    "url": "https://data.onxecta.com/api/production/wells",
    "servers": [
      {
        "url": "https://data.onxecta.com/api/production/wells",
        "description": "AWS Cloud API Endpoint"
      },
      {
        "url": "http://localhost/api/production/wells",
        "description": "Local Testing API Endpoint"
      }
    ],
    "name": "Bulk Add / Update Well Data",
    "description": "",
    "contentType": "application/json",
    "request": {
      "pathParameters": [],
      "headerParameters": [
        {
          "name": "accept",
          "type": "string",
          "kind": "optional",
          "description": "Generated from available response content types",
          "enum": [
            "application/json"
          ],
          "default": "application/json"
        }
      ],
      "queryParameters": [],
      "bodyDataParameters": [
        {
          "kind": "required",
          "name": "body",
          "type": "array",
          "description": "",
          "customType": "WellInput[]",
          "schema": [
            {
              "name": "sourceId",
              "kind": "required",
              "type": "string",
              "description": "<p>Well sourceId (commonly OpenWells or WellView ID - used to link to other construction data)</p>",
              "maxLength": 100
            },
            {
              "name": "uwi",
              "kind": "required",
              "type": "string",
              "description": "<p>Well UWI (commonly the API number - used to link to daily production)</p>"
            },
            {
              "name": "name",
              "kind": "required",
              "type": "string",
              "description": "Well Name",
              "maxLength": 100
            },
            {
              "name": "group1",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "<p>Group 1 - used for primary group navigation in the application</p>",
              "minLength": 2,
              "maxLength": 100,
              "pattern": "^[a-zA-Z0-9\\-_()#& ]+$"
            },
            {
              "name": "group2",
              "kind": "optional",
              "type": "string",
              "deprecated": true,
              "nullable": true,
              "description": "Warning: Deprecated\n<p>Group 2 - used for secondary sorting in the well tree and grouping in the application\nNOTE: This field has been deprecated and will be removed in January 2026.\nPlease use area, centralFacility, tankBattery, route, pad, platform to organize the well.</p>",
              "maxLength": 100
            },
            {
              "name": "group3",
              "kind": "optional",
              "type": "string",
              "deprecated": true,
              "nullable": true,
              "description": "Warning: Deprecated\n<p>Group 3 - used for secondary sorting in the well tree and grouping in the application\nNOTE: This field has been deprecated and will be removed in January 2026.\nPlease use area, centralFacility, tankBattery, route, pad, platform to organize the well.</p>",
              "maxLength": 100
            },
            {
              "name": "area",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "<p>Sub-area of a field/asset defined by group1</p>",
              "maxLength": 100
            },
            {
              "name": "centralFacility",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "Central facility into which the well flows",
              "maxLength": 100
            },
            {
              "name": "tankBattery",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "Tank battery into which the well flows",
              "maxLength": 100
            },
            {
              "name": "route",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "Route on which the well is located",
              "maxLength": 100
            },
            {
              "name": "pad",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "<p>Pad (if applicable) on which the well is located</p>",
              "maxLength": 100
            },
            {
              "name": "platform",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "<p>Platform (if applicable) to which the well flows</p>",
              "maxLength": 100
            },
            {
              "name": "heritage",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "Heritage of the well",
              "maxLength": 100
            },
            {
              "name": "responsibleEngineer",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "Engineer responsible for the well",
              "maxLength": 100
            },
            {
              "name": "type",
              "kind": "optional",
              "type": "string",
              "description": "<p>Well type: PRODUCER, INJECTOR</p>",
              "default": "PRODUCER",
              "modelRef": "#/components/schemas/WellType",
              "customType": "WellType",
              "schema": []
            },
            {
              "name": "fluid",
              "kind": "optional",
              "type": "string",
              "description": "",
              "default": "OIL",
              "modelRef": "#/components/schemas/FluidType",
              "customType": "FluidType",
              "schema": []
            },
            {
              "name": "liftType",
              "kind": "optional",
              "type": "string",
              "description": "<p>Current lift type of the well: NATURAL_FLOW, GAS_LIFT, ROD_PUMP, ESP, PLUNGER_LIFT, PLUNGER_ASSISTED_GAS_LIFT, GAS_ASSISTED_PLUNGER_LIFT, ANNULAR_NATURAL_FLOW, ANNULAR_GAS_LIFT, PCP, DUAL_NATURAL_FLOW</p>",
              "default": "NATURAL_FLOW",
              "modelRef": "#/components/schemas/LiftType",
              "customType": "LiftType",
              "schema": []
            },
            {
              "name": "lat",
              "kind": "required",
              "type": "number<double>",
              "description": "<p>Surface latitude in WGS84, decimal degrees</p>",
              "format": "double"
            },
            {
              "name": "lon",
              "kind": "required",
              "type": "number<double>",
              "description": "<p>Surface longitude in WGS84, decimal degrees</p>",
              "format": "double"
            },
            {
              "name": "middleLat",
              "kind": "optional",
              "type": "number<double>",
              "nullable": true,
              "description": "<p>Optional middle coordinate (for maps). Frequently the lateral heel coordinates.</p>",
              "format": "double"
            },
            {
              "name": "middleLon",
              "kind": "optional",
              "type": "number<double>",
              "nullable": true,
              "description": "<p>Optional middle coordinate (for maps). Frequently the lateral heel coordinates.</p>",
              "format": "double"
            },
            {
              "name": "mudLine",
              "kind": "optional",
              "type": "number<double>",
              "nullable": true,
              "description": "<p>Mud line for offshore wells, ft</p>",
              "format": "double"
            },
            {
              "name": "status",
              "kind": "optional",
              "type": "string",
              "nullable": true,
              "description": "",
              "modelRef": "#/components/schemas/WellStatus",
              "customType": "WellStatus",
              "schema": []
            },
            {
              "name": "bottomholeLat",
              "kind": "optional",
              "type": "number<double>",
              "nullable": true,
              "description": "",
              "format": "double"
            },
            {
              "name": "bottomholeLon",
              "kind": "optional",
              "type": "number<double>",
              "nullable": true,
              "description": "",
              "format": "double"
            }
          ],
          "modelRef": "#/components/schemas/WellInput",
          "isExpanded": true
        }
      ],
      "formDataParameters": [],
      "oAuthParameters": [
        {
          "id": "bearerAuth",
          "name": "bearerAuth",
          "kind": "optional",
          "type": "http",
          "scheme": "bearer"
        }
      ],
      "cookieParameters": []
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "OK",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "array",
            "description": "",
            "customType": "Well[]",
            "schema": [
              {
                "name": "xid",
                "kind": "required",
                "type": "string<uuid>",
                "description": "",
                "format": "uuid"
              },
              {
                "name": "sourceId",
                "kind": "required",
                "type": "string",
                "description": ""
              },
              {
                "name": "uwi",
                "kind": "required",
                "type": "string",
                "description": ""
              },
              {
                "name": "name",
                "kind": "required",
                "type": "string",
                "description": ""
              },
              {
                "name": "group1",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "<p>Group 1 - used for primary group navigation in the application</p>"
              },
              {
                "name": "group2",
                "kind": "optional",
                "type": "string",
                "deprecated": true,
                "nullable": true,
                "description": "Warning: Deprecated\n<p>Group 2 - used for secondary sorting in the well tree and grouping in the application\nNOTE: This field has been deprecated and will be removed in January 2026.\nPlease use area, centralFacility, tankBattery, route, pad, platform to organize the well.</p>"
              },
              {
                "name": "group3",
                "kind": "optional",
                "type": "string",
                "deprecated": true,
                "nullable": true,
                "description": "Warning: Deprecated\n<p>Group 3 - used for secondary sorting in the well tree and grouping in the application\nNOTE: This field has been deprecated and will be removed in January 2026.\nPlease use area, centralFacility, tankBattery, route, pad, platform to organize the well.</p>"
              },
              {
                "name": "area",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "<p>Sub-area of a field/asset defined by group1</p>"
              },
              {
                "name": "centralFacility",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Central facility into which the well flows"
              },
              {
                "name": "tankBattery",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Tank battery into which the well flows"
              },
              {
                "name": "route",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Route on which the well is located"
              },
              {
                "name": "pad",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "<p>Pad (if applicable) on which the well is located</p>"
              },
              {
                "name": "platform",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "<p>Platform (if applicable) to which the well flows</p>"
              },
              {
                "name": "heritage",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Heritage of the well"
              },
              {
                "name": "responsibleEngineer",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "Engineer responsible for the well"
              },
              {
                "name": "type",
                "kind": "optional",
                "type": "string",
                "description": "<p>Well type: PRODUCER, INJECTOR</p>",
                "default": "PRODUCER",
                "modelRef": "#/components/schemas/WellType",
                "customType": "WellType",
                "schema": []
              },
              {
                "name": "fluid",
                "kind": "optional",
                "type": "string",
                "description": "",
                "default": "OIL",
                "modelRef": "#/components/schemas/FluidType",
                "customType": "FluidType",
                "schema": []
              },
              {
                "name": "liftType",
                "kind": "optional",
                "type": "string",
                "description": "<p>Current lift type of the well: NATURAL_FLOW, GAS_LIFT, ROD_PUMP, ESP, PLUNGER_LIFT, PLUNGER_ASSISTED_GAS_LIFT, GAS_ASSISTED_PLUNGER_LIFT, ANNULAR_NATURAL_FLOW, ANNULAR_GAS_LIFT, PCP, DUAL_NATURAL_FLOW</p>",
                "default": "NATURAL_FLOW",
                "modelRef": "#/components/schemas/LiftType",
                "customType": "LiftType",
                "schema": []
              },
              {
                "name": "lat",
                "kind": "required",
                "type": "number<double>",
                "description": "",
                "format": "double"
              },
              {
                "name": "lon",
                "kind": "required",
                "type": "number<double>",
                "description": "",
                "format": "double"
              },
              {
                "name": "mudLine",
                "kind": "optional",
                "type": "number<double>",
                "nullable": true,
                "description": "",
                "format": "double"
              },
              {
                "name": "middleLat",
                "kind": "optional",
                "type": "number<double>",
                "nullable": true,
                "description": "<p>Optional middle coordinate (for maps). Frequently the lateral heel coordinates.</p>",
                "format": "double"
              },
              {
                "name": "middleLon",
                "kind": "optional",
                "type": "number<double>",
                "nullable": true,
                "description": "<p>Optional middle coordinate (for maps). Frequently the lateral heel coordinates.</p>",
                "format": "double"
              },
              {
                "name": "status",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": "",
                "modelRef": "#/components/schemas/WellStatus",
                "customType": "WellStatus",
                "schema": []
              },
              {
                "name": "timezone",
                "kind": "optional",
                "type": "string",
                "nullable": true,
                "description": ""
              },
              {
                "name": "bottomholeLat",
                "kind": "optional",
                "type": "number<double>",
                "nullable": true,
                "description": "",
                "format": "double"
              },
              {
                "name": "bottomholeLon",
                "kind": "optional",
                "type": "number<double>",
                "nullable": true,
                "description": "",
                "format": "double"
              }
            ],
            "modelRef": "#/components/schemas/Well",
            "isExpanded": true
          }
        ]
      }
    ],
    "hasXCodeSamples": false,
    "examples": {
      "languages": [
        {
          "id": "R3shYtKui5EBgpP96FtAy",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request POST \\\n     --url https://data.onxecta.com/api/production/wells \\\n     --header 'accept: application/json' \\\n     --header 'content-type: application/json' \\\n     --data '[\n     {\n     \"sourceId\": \"\",\n     \"uwi\": \"\",\n     \"name\": \"\",\n     \"type\": \"PRODUCER\",\n     \"fluid\": \"OIL\",\n     \"liftType\": \"NATURAL_FLOW\",\n     \"lat\": \"\",\n     \"lon\": \"\"\n     }\n     ]'"
        },
        {
          "id": "7kh76oREHUW4wiDdcncKg",
          "language": "javascript",
          "label": "javascript",
          "code": "var myHeaders = new Headers();\nmyHeaders.append(\"accept\", \"application/json\");\nmyHeaders.append(\"content-type\", \"application/json\");\n\nvar raw = JSON.stringify([\n   {\n      \"sourceId\": \"\",\n      \"uwi\": \"\",\n      \"name\": \"\",\n      \"type\": \"PRODUCER\",\n      \"fluid\": \"OIL\",\n      \"liftType\": \"NATURAL_FLOW\",\n      \"lat\": \"\",\n      \"lon\": \"\"\n   }\n]);\n\nvar requestOptions = {\n   method: 'POST',\n   headers: myHeaders,\n   body: raw,\n   redirect: 'follow'\n};\n\nfetch(\"https://data.onxecta.com/api/production/wells\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "qDDCm2T8ZqnLDePYCHU8S",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"https://data.onxecta.com/api/production/wells\"\n\npayload = json.dumps([\n   {\n      \"sourceId\": \"\",\n      \"uwi\": \"\",\n      \"name\": \"\",\n      \"type\": \"PRODUCER\",\n      \"fluid\": \"OIL\",\n      \"liftType\": \"NATURAL_FLOW\",\n      \"lat\": \"\",\n      \"lon\": \"\"\n   }\n])\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"POST\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        },
        {
          "id": "EYdHIJR8pmZMFFJyNX0C5",
          "language": "csharp",
          "label": "C#",
          "code": "var options = new RestClientOptions(\"https://data.onxecta.com\")\n{\n   MaxTimeout = -1,\n};\nvar client = new RestClient(options);\nvar request = new RestRequest(\"/api/production/wells\", Method.Post);\nrequest.AddHeader(\"accept\", \"application/json\");\nrequest.AddHeader(\"content-type\", \"application/json\");\nvar body = @\"[\" + \"\\n\" +\n@\"  {\" + \"\\n\" +\n@\"    \"\"sourceId\"\": \"\"\"\",\" + \"\\n\" +\n@\"    \"\"uwi\"\": \"\"\"\",\" + \"\\n\" +\n@\"    \"\"name\"\": \"\"\"\",\" + \"\\n\" +\n@\"    \"\"type\"\": \"\"PRODUCER\"\",\" + \"\\n\" +\n@\"    \"\"fluid\"\": \"\"OIL\"\",\" + \"\\n\" +\n@\"    \"\"liftType\"\": \"\"NATURAL_FLOW\"\",\" + \"\\n\" +\n@\"    \"\"lat\"\": \"\"\"\",\" + \"\\n\" +\n@\"    \"\"lon\"\": \"\"\"\"\" + \"\\n\" +\n@\"  }\" + \"\\n\" +\n@\"]\";\nrequest.AddStringBody(body, DataFormat.Json);\nRestResponse response = await client.ExecuteAsync(request);\nConsole.WriteLine(response.Content);"
        },
        {
          "id": "sTWt7qSrbvnSByYTTVg_l",
          "language": "java",
          "label": "Java",
          "code": "OkHttpClient client = new OkHttpClient().newBuilder()\n   .build();\nMediaType mediaType = MediaType.parse(\"application/json\");\nRequestBody body = RequestBody.create(mediaType, \"[\\n  {\\n    \\\"sourceId\\\": \\\"\\\",\\n    \\\"uwi\\\": \\\"\\\",\\n    \\\"name\\\": \\\"\\\",\\n    \\\"type\\\": \\\"PRODUCER\\\",\\n    \\\"fluid\\\": \\\"OIL\\\",\\n    \\\"liftType\\\": \\\"NATURAL_FLOW\\\",\\n    \\\"lat\\\": \\\"\\\",\\n    \\\"lon\\\": \\\"\\\"\\n  }\\n]\");\nRequest request = new Request.Builder()\n   .url(\"https://data.onxecta.com/api/production/wells\")\n   .method(\"POST\", body)\n   .addHeader(\"accept\", \"application/json\")\n   .addHeader(\"content-type\", \"application/json\")\n   .build();\nResponse response = client.newCall(request).execute();"
        }
      ],
      "selectedLanguageId": "R3shYtKui5EBgpP96FtAy"
    },
    "results": {
      "languages": [
        {
          "id": "potvkVTtx83l6s1y4VshU",
          "language": "200",
          "code": "// OK\n[\n  {\n    \"xid\": \"\",\n    \"sourceId\": \"\",\n    \"uwi\": \"\",\n    \"name\": \"\",\n    \"group1\": \"\",\n    \"group2\": \"\",\n    \"group3\": \"\",\n    \"area\": \"\",\n    \"centralFacility\": \"\",\n    \"tankBattery\": \"\",\n    \"route\": \"\",\n    \"pad\": \"\",\n    \"platform\": \"\",\n    \"heritage\": \"\",\n    \"responsibleEngineer\": \"\",\n    \"type\": \"\",\n    \"fluid\": \"\",\n    \"liftType\": \"\",\n    \"lat\": \"\",\n    \"lon\": \"\",\n    \"mudLine\": \"\",\n    \"middleLat\": \"\",\n    \"middleLon\": \"\",\n    \"status\": \"\",\n    \"timezone\": \"\",\n    \"bottomholeLat\": \"\",\n    \"bottomholeLon\": \"\"\n  }\n]"
        }
      ],
      "selectedLanguageId": "potvkVTtx83l6s1y4VshU"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}