entities-spec.json 5.73 KB
Newer Older
canterafonsj's avatar
canterafonsj committed
1
{
canterafonsj's avatar
canterafonsj committed
2
3
  "openapi": "3.0.1",
  "info": {
canterafonsj's avatar
canterafonsj committed
4
5
    "title": "NGSI-LD Entity Operations",
    "version": "0.1"
canterafonsj's avatar
canterafonsj committed
6
  },
canterafonsj's avatar
canterafonsj committed
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
  "components": {},
  "paths": {
    "/entityOperations/create": {
      "post": {
        "description": "Batch Entity creation",
        "operationId": "batchEntityCreation",
        "requestBody": {
          "required": true,
          "content": {
            "application/json;application/ld+json": {
              "schema": {
                "$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/EntityList.json#/definitions/EntityList"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json;application/ld+json": {
                "schema": {
                  "$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/BatchOperationResult.json#/definitions/BatchOperationResult"
                }
              }
            }
          },
          "400": {
            "description": "Bad request",
            "content": {
              "application/json;application/ld+json": {
                "schema": {
                  "$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/common.json#/definitions/ProblemDetails"
                }
              }
            }
          }
44
        }
canterafonsj's avatar
canterafonsj committed
45
      }
canterafonsj's avatar
canterafonsj committed
46
47
48
49
50
    },
    "/entityOperations/update": {
      "post": {
        "description": "Batch Entity update",
        "operationId": "batchEntityUpdate",
canterafonsj's avatar
canterafonsj committed
51
52
        "parameters": [
          {
canterafonsj's avatar
canterafonsj committed
53
54
55
56
57
58
59
60
61
            "name": "options",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "noOverwrite"
              ]
            }
canterafonsj's avatar
canterafonsj committed
62
63
          }
        ],
canterafonsj's avatar
canterafonsj committed
64
65
66
67
68
69
70
71
72
73
        "requestBody": {
          "required": true,
          "content": {
            "application/json;application/ld+json": {
              "schema": {
                "$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/EntityList.json#/definitions/EntityList"
              }
            }
          }
        },
canterafonsj's avatar
canterafonsj committed
74
75
        "responses": {
          "200": {
canterafonsj's avatar
canterafonsj committed
76
            "description": "Success",
canterafonsj's avatar
canterafonsj committed
77
78
79
            "content": {
              "application/json;application/ld+json": {
                "schema": {
canterafonsj's avatar
canterafonsj committed
80
                  "$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/BatchOperationResult.json#/definitions/BatchOperationResult"
canterafonsj's avatar
canterafonsj committed
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
                }
              }
            }
          },
          "400": {
            "description": "Bad request",
            "content": {
              "application/json;application/ld+json": {
                "schema": {
                  "$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/common.json#/definitions/ProblemDetails"
                }
              }
            }
          }
        }
canterafonsj's avatar
canterafonsj committed
96
97
98
      }
    },
    "/entityOperations/upsert": {
canterafonsj's avatar
canterafonsj committed
99
      "post": {
canterafonsj's avatar
canterafonsj committed
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
        "description": "Batch Entity upsert",
        "operationId": "batchEntityUpsert",
        "parameters": [
          {
            "name": "options",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "replace",
                "update"
              ]
            }
          }
        ],
canterafonsj's avatar
canterafonsj committed
116
117
118
119
120
        "requestBody": {
          "required": true,
          "content": {
            "application/json;application/ld+json": {
              "schema": {
canterafonsj's avatar
canterafonsj committed
121
                "$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/EntityList.json#/definitions/EntityList"
canterafonsj's avatar
canterafonsj committed
122
123
124
125
126
              }
            }
          }
        },
        "responses": {
canterafonsj's avatar
canterafonsj committed
127
128
129
130
131
132
133
134
135
          "200": {
            "description": "Success",
            "content": {
              "application/json;application/ld+json": {
                "schema": {
                  "$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/BatchOperationResult.json#/definitions/BatchOperationResult"
                }
              }
            }
canterafonsj's avatar
canterafonsj committed
136
137
138
139
140
141
142
143
144
145
          },
          "400": {
            "description": "Bad request",
            "content": {
              "application/json;application/ld+json": {
                "schema": {
                  "$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/common.json#/definitions/ProblemDetails"
                }
              }
            }
canterafonsj's avatar
canterafonsj committed
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
          }
        }
      }
    },
    "/entityOperations/delete": {
      "post": {
        "description": "Batch Entity delete",
        "operationId": "batchEntityDelete",
        "requestBody": {
          "required": true,
          "content": {
            "application/json;application/ld+json": {
              "schema": {
                "type": "array",
                "items": {
                  "type": "string",
                  "format": "uri"
                },
                "minItems": 1
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Success",
canterafonsj's avatar
canterafonsj committed
172
173
174
            "content": {
              "application/json;application/ld+json": {
                "schema": {
canterafonsj's avatar
canterafonsj committed
175
                  "$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/BatchOperationResult.json#/definitions/BatchOperationResult"
canterafonsj's avatar
canterafonsj committed
176
177
178
179
                }
              }
            }
          },
canterafonsj's avatar
canterafonsj committed
180
181
          "400": {
            "description": "Bad request",
canterafonsj's avatar
canterafonsj committed
182
183
184
185
186
187
188
189
190
191
192
193
            "content": {
              "application/json;application/ld+json": {
                "schema": {
                  "$ref": "https://forge.etsi.org/gitlab/NGSI-LD/NGSI-LD/raw/master/schema/common.json#/definitions/ProblemDetails"
                }
              }
            }
          }
        }
      }
    }
  }
canterafonsj's avatar
canterafonsj committed
194
}