openapi: 3.0.0
servers:
  - url: https://prod.api.market/api/v1/magicapi/nsfw
info:
  title: NSFW Detector API
  version: 1.1.8
  description: "NSFW Detector API: Uses ML to analyze images, videos, or text for
    inappropriate content, enabling safer online experiences. Empowers devs."
paths:
  /predictions/{request_id}:
    get:
      summary: Get Toonified Image URL
      description: >
        This endpoint retrieves the URL of the toonified image for a given
        request ID.
      parameters:
        - name: request_id
          in: path
          required: true
          description: Unique identifier for the request.
          schema:
            type: string
      responses:
        "200":
          description: Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    description: Status of the prediction (e.g., "succeeded").
                  image_url:
                    type: string
                    format: uri
                    description: URL of the toonified image.
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Description of the error.
      security:
        - apiKey: []
    parameters:
      - &a1
        description: API.market API Key
        in: header
        name: x-api-market-key
        value: Please Login/Signup to get an API Key
        required: true
        schema:
          type: string
  /nsfw:
    post:
      summary: NSFW Detector
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                image:
                  type: string
                  default: https://replicate.delivery/mgxm/f4e50a7b-e8ca-432f-8e68-082034ebcc70/demo.jpg
              required:
                - image
      responses:
        "200":
          description: Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  request_id:
                    type: string
                    description: Unique identifier for the request.
        "400":
          description: Bad Request
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Description of the error.
      security:
        - apiKey: []
    parameters:
      - *a1
security: {}
tags:
  - name: cybersecurity
    description: Operations related to cybersecurity
  - name: visual-recognition
    description: Operations related to visual-recognition
  - name: artificial-intelligence
    description: Operations related to artificial-intelligence
