openapi: 3.0.0 info: title: Example of links with callbacks version: 0.9.0 paths: /hooks: post: requestBody: description: body provided by consumer with callback URL required: true content: application/json: example: callback-url: https://consumer.com/hookcallback responses: '201': description: Successfully subscribed content: application/json: example: hookId: 23432-32432-45454-97980 links: unsubscribe: operationId: cancelHookCallback parameters: id: $response.body#/hookId callbacks: hookEvent: '$request.body#/callback-url': post: requestBody: content: application/json: example: message: Here is the event responses: '200': description: Expected responses from callback consumer /hooks/{id}: delete: operationId: cancelHookCallback parameters: name: id in: path schema: type: string responses: '200': description: Successfully cancelled callback