|
55 | 55 | "paths": { |
56 | 56 | "/topics/{topicName}:publish": { |
57 | 57 | "post": { |
58 | | - "operationId": "PublishCloudEvents", |
59 | | - "description": "Publish Batch Cloud Event to namespace topic. In case of success, the server responds with an HTTP 200 status code with an empty JSON object in response. Otherwise, the server can return various error codes. For example, 401: which indicates authorization failure, 403: which indicates quota exceeded or message is too large, 410: which indicates that specific topic is not found, 400: for bad request, and 500: for internal server error. ", |
| 58 | + "operationId": "PublishCloudEvent", |
| 59 | + "description": "Publish Single Cloud Event to namespace topic. In case of success, the server responds with an HTTP 200 status code with an empty JSON object in response. Otherwise, the server can return various error codes. For example, 401: which indicates authorization failure, 403: which indicates quota exceeded or message is too large, 410: which indicates that specific topic is not found, 400: for bad request, and 500: for internal server error. ", |
60 | 60 | "consumes": [ |
61 | | - "application/cloudevents-batch+json; charset=utf-8" |
| 61 | + "application/cloudevents+json; charset=utf-8" |
62 | 62 | ], |
63 | 63 | "parameters": [ |
64 | 64 | { |
|
72 | 72 | "type": "string" |
73 | 73 | }, |
74 | 74 | { |
75 | | - "name": "events", |
| 75 | + "name": "event", |
76 | 76 | "in": "body", |
77 | | - "description": "Array of Cloud Events being published.", |
| 77 | + "description": "Single Cloud Event being published.", |
78 | 78 | "required": true, |
79 | 79 | "schema": { |
80 | | - "type": "array", |
81 | | - "items": { |
82 | | - "$ref": "#/definitions/CloudEvent" |
83 | | - } |
| 80 | + "$ref": "#/definitions/CloudEvent" |
84 | 81 | } |
85 | 82 | } |
86 | 83 | ], |
|
103 | 100 | } |
104 | 101 | } |
105 | 102 | } |
106 | | - }, |
107 | | - "x-ms-examples": { |
108 | | - "Publish Cloud Event": { |
109 | | - "$ref": "./examples/publish.json" |
110 | | - } |
111 | 103 | } |
112 | 104 | } |
113 | 105 | }, |
|
358 | 350 | } |
359 | 351 | } |
360 | 352 | }, |
| 353 | + "x-ms-paths": { |
| 354 | + "/topics/{topicName}:publish?_overload=publishCloudEvents": { |
| 355 | + "post": { |
| 356 | + "operationId": "PublishCloudEvents", |
| 357 | + "description": "Publish Batch Cloud Event to namespace topic. In case of success, the server responds with an HTTP 200 status code with an empty JSON object in response. Otherwise, the server can return various error codes. For example, 401: which indicates authorization failure, 403: which indicates quota exceeded or message is too large, 410: which indicates that specific topic is not found, 400: for bad request, and 500: for internal server error. ", |
| 358 | + "consumes": [ |
| 359 | + "application/cloudevents-batch+json; charset=utf-8" |
| 360 | + ], |
| 361 | + "parameters": [ |
| 362 | + { |
| 363 | + "$ref": "#/parameters/Azure.Core.Foundations.ApiVersionParameter" |
| 364 | + }, |
| 365 | + { |
| 366 | + "name": "topicName", |
| 367 | + "in": "path", |
| 368 | + "description": "Topic Name.", |
| 369 | + "required": true, |
| 370 | + "type": "string" |
| 371 | + }, |
| 372 | + { |
| 373 | + "name": "events", |
| 374 | + "in": "body", |
| 375 | + "description": "Array of Cloud Events being published.", |
| 376 | + "required": true, |
| 377 | + "schema": { |
| 378 | + "type": "array", |
| 379 | + "items": { |
| 380 | + "$ref": "#/definitions/CloudEvent" |
| 381 | + } |
| 382 | + } |
| 383 | + } |
| 384 | + ], |
| 385 | + "responses": { |
| 386 | + "200": { |
| 387 | + "description": "The request has succeeded.", |
| 388 | + "schema": { |
| 389 | + "$ref": "#/definitions/PublishResult" |
| 390 | + } |
| 391 | + }, |
| 392 | + "default": { |
| 393 | + "description": "An unexpected error response.", |
| 394 | + "schema": { |
| 395 | + "$ref": "#/definitions/Azure.Core.Foundations.ErrorResponse" |
| 396 | + }, |
| 397 | + "headers": { |
| 398 | + "x-ms-error-code": { |
| 399 | + "type": "string", |
| 400 | + "description": "String error code indicating what went wrong." |
| 401 | + } |
| 402 | + } |
| 403 | + } |
| 404 | + }, |
| 405 | + "x-ms-examples": { |
| 406 | + "Publish Cloud Event": { |
| 407 | + "$ref": "./examples/publish.json" |
| 408 | + } |
| 409 | + } |
| 410 | + } |
| 411 | + } |
| 412 | + }, |
361 | 413 | "definitions": { |
362 | 414 | "AcknowledgeOptions": { |
363 | 415 | "type": "object", |
|
0 commit comments