{
 "openapi": "3.1.0",
 "info": {
  "title": "WMS Connections (Supply Chain)",
  "version": "20261030b",
  "description": "Another system already runs the warehouse. Map its field names to these and its movements arrive as scan sessions — no code changes to take another one on."
 },
 "servers": [
  {
   "url": "https://{tenant}.tranxact.ai",
   "variables": {
    "tenant": {
     "default": "demo"
    }
   }
  }
 ],
 "components": {
  "securitySchemes": {
   "bearer": {
    "type": "http",
    "scheme": "bearer"
   }
  },
  "schemas": {
   "wms-systems": {
    "type": "object",
    "required": [
     "code",
     "name"
    ],
    "properties": {
     "id": {
      "type": "string",
      "format": "uuid",
      "description": "Id",
      "readOnly": true
     },
     "org_id": {
      "type": "string",
      "format": "uuid",
      "description": "Org id",
      "readOnly": true
     },
     "code": {
      "type": "string",
      "description": "System code"
     },
     "name": {
      "type": "string",
      "description": "Name"
     },
     "vendor": {
      "type": "string",
      "description": "Vendor"
     },
     "system_type": {
      "type": "string",
      "description": "Type",
      "enum": [
       "wms",
       "wcs",
       "tms",
       "3pl",
       "erp",
       "mes",
       "other"
      ]
     },
     "direction": {
      "type": "string",
      "description": "Direction",
      "enum": [
       "inbound",
       "outbound",
       "bidirectional"
      ]
     },
     "payload_format": {
      "type": "string",
      "description": "Payload format"
     },
     "connection_id": {
      "type": "string",
      "format": "uuid",
      "description": "Platform connection"
     },
     "warehouse_id": {
      "type": "string",
      "format": "uuid",
      "description": "Warehouse"
     },
     "unknown_item_policy": {
      "type": "string",
      "description": "When the item is unknown",
      "enum": [
       "reject",
       "hold",
       "create"
      ]
     },
     "auto_post": {
      "type": "boolean",
      "description": "Post its movements automatically"
     },
     "status": {
      "type": "string",
      "description": "Status",
      "enum": [
       "draft",
       "configured",
       "active",
       "error",
       "disabled"
      ]
     },
     "message_count": {
      "type": "integer",
      "description": "Message count",
      "readOnly": true
     },
     "error_count": {
      "type": "integer",
      "description": "Error count",
      "readOnly": true
     },
     "last_message_at": {
      "type": "string",
      "format": "date-time",
      "description": "Last message at",
      "readOnly": true
     },
     "notes": {
      "type": "string",
      "description": "Notes"
     },
     "created_at": {
      "type": "string",
      "format": "date-time",
      "description": "Created at",
      "readOnly": true
     },
     "org_unit_id": {
      "type": "string",
      "format": "uuid",
      "description": "Org unit id",
      "readOnly": true
     },
     "xf_text_1": {
      "type": "string",
      "description": "Xf text 1",
      "readOnly": true
     },
     "xf_text_2": {
      "type": "string",
      "description": "Xf text 2",
      "readOnly": true
     },
     "xf_text_3": {
      "type": "string",
      "description": "Xf text 3",
      "readOnly": true
     },
     "xf_text_4": {
      "type": "string",
      "description": "Xf text 4",
      "readOnly": true
     },
     "xf_text_5": {
      "type": "string",
      "description": "Xf text 5",
      "readOnly": true
     },
     "xf_num_1": {
      "type": "string",
      "format": "decimal",
      "description": "Xf num 1",
      "readOnly": true
     },
     "xf_num_2": {
      "type": "string",
      "format": "decimal",
      "description": "Xf num 2",
      "readOnly": true
     },
     "xf_num_3": {
      "type": "string",
      "format": "decimal",
      "description": "Xf num 3",
      "readOnly": true
     },
     "xf_date_1": {
      "type": "string",
      "format": "date",
      "description": "Xf date 1",
      "readOnly": true
     },
     "xf_date_2": {
      "type": "string",
      "format": "date",
      "description": "Xf date 2",
      "readOnly": true
     },
     "created_by": {
      "type": "string",
      "format": "uuid",
      "description": "Created by",
      "readOnly": true
     },
     "updated_at": {
      "type": "string",
      "format": "date-time",
      "description": "Updated at",
      "readOnly": true
     },
     "updated_by": {
      "type": "string",
      "format": "uuid",
      "description": "Updated by",
      "readOnly": true
     }
    }
   }
  }
 },
 "security": [
  {
   "bearer": []
  }
 ],
 "paths": {
  "/api/scm/wms-systems": {
   "get": {
    "summary": "list wms-systems",
    "operationId": "list_wms_systems_0_4",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   },
   "post": {
    "summary": "create wms-systems",
    "operationId": "create_wms_systems_1_4",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   }
  },
  "/api/scm/wms-systems/{id}": {
   "get": {
    "summary": "get wms-systems",
    "operationId": "get_wms_systems_0_5",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   },
   "put": {
    "summary": "change wms-systems",
    "operationId": "change_wms_systems_1_5",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   },
   "delete": {
    "summary": "delete wms-systems",
    "operationId": "delete_wms_systems_2_5",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   }
  },
  "/api/scm/wms-systems/{id}/copy": {
   "post": {
    "summary": "Copy",
    "operationId": "action_wms_systems_0_6",
    "description": "Body keys: overrides, preview, withLines",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   }
  },
  "/api/scm/wms-systems/{id}/preview-mapping": {
   "post": {
    "summary": "Preview mapping",
    "operationId": "action_wms_systems_0_6",
    "description": "Body keys: records, record",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   }
  },
  "/api/scm/wms-systems/{id}/inbound": {
   "post": {
    "summary": "Inbound",
    "operationId": "action_wms_systems_0_6",
    "description": "Body keys: movementType, externalRef, records*; movementType one of goods_receipt|goods_issue|transfer|physical_inventory|cycle_count|scrap|return_to_vendor|put_away|pick|initial_stock",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   }
  },
  "/api/scm/wms-systems/{parentId}/mappings": {
   "get": {
    "summary": "Mappings",
    "operationId": "action_wms_systems_0_6",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   },
   "post": {
    "summary": "Mappings",
    "operationId": "action_wms_systems_1_6",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   }
  },
  "/api/scm/wms-systems/{parentId}/mappings/{lineId}": {
   "put": {
    "summary": "Mappings",
    "operationId": "action_wms_systems_0_7",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   },
   "delete": {
    "summary": "Mappings",
    "operationId": "action_wms_systems_1_7",
    "responses": {
     "200": {
      "description": "OK"
     },
     "401": {
      "description": "No or bad credential"
     },
     "403": {
      "description": "Not granted"
     },
     "422": {
      "description": "Refused by validation"
     }
    }
   }
  }
 }
}