info:
  title: API title
  version: 0.0.1
swagger: '2.0'
produces:
  - application/json
host: localhost:3000
basePath: /api
tags:
  - name: posts
    description: Operations about posts
paths:
  /posts:
    get:
      description: Return list of posts
      produces:
        - application/json
      parameters:
        - in: query
          name: tag_string
          type: string
          default: ''
          required: false
          example: rating:dunno 2girls 1cup
        - in: query
          name: page
          description: Page offset to fetch.
          type: integer
          format: int32
          default: 1
          required: false
        - in: query
          name: per_page
          description: Number of items to return per page.
          type: integer
          format: int32
          default: 48
          required: false
      responses:
        '200':
          description: Return list of posts
          headers:
            Current-Page:
              type: number
            Page-Items:
              type: number
            Total-Count:
              type: number
            Total-Pages:
              type: number
            Link:
              type: string
          schema:
            $ref: '#/definitions/Hrefbooru_V1_Entities_SearchResult'
      tags:
        - posts
      operationId: getPosts
  /posts/{id}:
    get:
      description: Return a post
      produces:
        - application/json
      parameters:
        - in: path
          name: id
          description: Post ID
          type: integer
          format: int32
          required: true
      responses:
        '200':
          description: Return a post
          schema:
            $ref: '#/definitions/Hrefbooru_V1_Entities_Post'
      tags:
        - posts
      operationId: getPostsId
definitions:
  Hrefbooru_V1_Entities_SearchResult:
    type: object
    properties:
      posts:
        type: array
        items:
          $ref: '#/definitions/Hrefbooru_V1_Entities_SearchResultPost'
      tags:
        type: array
        items:
          $ref: '#/definitions/Hrefbooru_V1_Entities_Tag'
    description: Hrefbooru_V1_Entities_SearchResult model
  Hrefbooru_V1_Entities_SearchResultPost:
    type: object
    properties:
      id:
        type: string
      rating:
        type: string
      image:
        $ref: '#/definitions/Hrefbooru_V1_Entities_Image'
      created_at:
        type: string
      updated_at:
        type: string
  Hrefbooru_V1_Entities_Image:
    type: object
    properties:
      original:
        $ref: '#/definitions/Hrefbooru_V1_Entities_File'
      medium:
        $ref: '#/definitions/Hrefbooru_V1_Entities_File'
      thumbnail:
        $ref: '#/definitions/Hrefbooru_V1_Entities_File'
  Hrefbooru_V1_Entities_File:
    type: object
    properties:
      url:
        type: string
      height:
        type: string
      width:
        type: string
  Hrefbooru_V1_Entities_Tag:
    type: object
    properties:
      name:
        type: string
  Hrefbooru_V1_Entities_Post:
    type: object
    properties:
      id:
        type: string
      rating:
        type: string
      tags:
        type: array
        items:
          $ref: '#/definitions/Hrefbooru_V1_Entities_Tag'
      image:
        $ref: '#/definitions/Hrefbooru_V1_Entities_Image'
      created_at:
        type: string
      updated_at:
        type: string
    description: Hrefbooru_V1_Entities_Post model

Изменить пасту