openapi: 3.0.0 info: title: Meltwater Streaming API v3 description: The Meltwater Streaming API provides the needed resources for Meltwater clients to create & delete REST Hooks and stream Meltwater search results to your specified destination. version: 3.0.0 tags: - name: hooks description: Operations about hooks - name: schemas description: Operations about JSON schemas paths: /v3/hooks: get: summary: List all hooks. description: |- List all hooks. Delivers all previously generated hooks. parameters: - in: header name: apikey description: The `apikey` from [developer.meltwater.com](https://developer.meltwater.com/admin/applications/). required: true schema: type: string responses: "200": description: List all hooks. content: application/json: schema: $ref: "#/components/schemas/HooksCollection" "401": description: Invalid or expired token. "403": description: Not entitled to the service "500": description: Something went wrong while trying to fetch your hooks. tags: - hooks operationId: getAllHooks post: summary: Creates a hook for one of your predefined searches. description: >- Creates a hook for one of your predefined searches. Delivers search results for the query referenced by the `search_id` to the `target_url` via HTTP POST. Note that a `hook_id` will be returned on successful creation, this id is needed to delete the hook. We are also returning the header: `X-Hook-Secret`, a shared secret used to sign the document body pushed to your `target_url`. Specify `company_id` if your `search_id` is not in your default company. parameters: - in: header name: apikey description: The `apikey` from [developer.meltwater.com](https://developer.meltwater.com/admin/applications/). required: true schema: type: string - in: header name: X-Hook-Secret description: | Shared secret for content signing/verification. The shared secret header is optional and can be provided by the user or will be set by the API. Must be between 16 and 64 characters. Obtain the shared secret from the response header `X-Hook-Secret`. #### Example: e2d264b524240b9572ebc2fc7eebd980 required: false schema: type: string - in: query name: company_id description: Company that owns the specified search_id. If not specified your default company is used. required: false schema: type: string requestBody: content: application/json: schema: $ref: "#/components/schemas/postV2Hooks" required: true responses: "201": description: Successfully Created content: application/json: schema: $ref: "#/components/schemas/Hook" "400": description: Missing required parameters. "401": description: Invalid or expired token. "403": description: Not entitled to the service "404": description: The search you are trying to create a REST hook for was not found. content: application/json: schema: $ref: "#/components/schemas/ErrorsCollection" "409": description: The hook you are trying to create already exists for the specified search_id and target_url. "500": description: Something went wrong while trying to create your REST hook. content: application/json: schema: $ref: "#/components/schemas/ErrorsCollection" tags: - hooks operationId: createHook "/v3/hooks/{hook_id}": delete: summary: Delete an existing hook. description: >- Delete an existing hook. Removes the hook and stops sending any search results to the target_url. parameters: - in: header name: apikey description: The `apikey` from [developer.meltwater.com](https://developer.meltwater.com/admin/applications/). required: true schema: type: string - in: path name: hook_id description: Hook ID received from creating a hook required: true schema: type: string responses: "204": description: Successfully Deleted "400": description: Missing required parameters. "401": description: Invalid or expired token. "403": description: Not entitled to the service "404": description: The REST hook you are trying to delete was not found "500": description: Something went wrong while trying to delete your hook(-s). tags: - hooks operationId: deleteHook get: summary: Get an individual hook. description: |- Get an individual hook. Retrieves an existing hook. parameters: - in: header name: apikey description: The `apikey` from [developer.meltwater.com](https://developer.meltwater.com/admin/applications/). required: true schema: type: string - in: path name: hook_id description: Hook ID required: true schema: type: string responses: "200": description: Successfully Created content: application/json: schema: $ref: "#/components/schemas/SingleHook" "401": description: Invalid or expired token. "403": description: Not entitled to the service "404": description: The hook you are trying to get was not found content: application/json: schema: $ref: "#/components/schemas/ErrorsCollection" "500": description: Something went wrong while trying to fetch your hooks. tags: - hooks operationId: getHook /v3/schemas/social_streaming.json: get: summary: Social Streaming JSON schema description: Get the JSON schema describing the layout of Social Streaming documents. responses: "200": description: JSON schema for Social Streaming documents tags: - schemas operationId: getSocialStreamingJsonSchema parameters: - in: header name: apikey description: The `apikey` from [developer.meltwater.com](https://developer.meltwater.com/admin/applications/). required: true schema: type: string /v3/schemas/editorial_streaming.json: get: summary: Editorial Streaming JSON schema description: Get the JSON schema describing the layout of Editorial Streaming documents. responses: "200": description: JSON schema for Editorial Streaming documents tags: - schemas operationId: getEditorialStreamingJsonSchema parameters: - in: header name: apikey description: The `apikey` from [developer.meltwater.com](https://developer.meltwater.com/admin/applications/). required: true schema: type: string /v3/schemas/broadcast_streaming.json: get: summary: Broadcast Streaming JSON schema description: Get the JSON schema describing the layout of Broadcast Streaming documents. responses: "200": description: JSON schema for Broadcast Streaming documents tags: - schemas operationId: getBroadcastStreamingJsonSchema parameters: - in: header name: apikey description: The `apikey` from [developer.meltwater.com](https://developer.meltwater.com/admin/applications/). required: true schema: type: string servers: - url: https://api.meltwater.com components: schemas: HooksCollection: type: object properties: hooks: type: array items: $ref: "#/components/schemas/Hook" description: |- List all hooks. Delivers all previously generated hooks. Hook: type: object properties: search_id: type: integer format: int32 description: Search id target_url: type: string description: The URL that results from the search will be posted to updated: type: string search_type: type: string description: The type of search the hook is for hook_id: type: string version: type: string description: |- Get an individual hook. Retrieves an existing hook. postV2Hooks: type: object properties: target_url: type: string description: Target URL to send article results search_id: type: integer format: int32 description: Search ID required: - target_url - search_id description: Creates a hook for one of your predefined searches. ErrorsCollection: type: object properties: errors: type: array items: $ref: "#/components/schemas/Error" Error: type: object properties: details: type: string description: Human-readable error message. title: type: string description: Error title type: type: string description: Error category meta: type: object description: Additional meta-information to qualify error SingleHook: type: object properties: hook: $ref: "#/components/schemas/Hook" description: |- Get an individual hook. Retrieves an existing hook.