definitions: entity.ConfigSpiderData: properties: cmd: description: 自定义爬虫 type: string col: type: string display_name: type: string engine: description: 可配置爬虫 type: string name: description: 通用 type: string remark: type: string settings: type: object stages: items: $ref: '#/definitions/entity.Stage' type: array start_stage: type: string start_url: type: string type: type: string type: object entity.Field: properties: attr: type: string css: type: string name: type: string next_stage: type: string remark: type: string xpath: type: string type: object entity.ScrapyItem: properties: fields: items: type: string type: array name: type: string type: object entity.ScrapySettingParam: properties: key: type: string type: type: string value: type: object type: object entity.Stage: properties: fields: items: $ref: '#/definitions/entity.Field' type: array is_list: type: boolean list_css: type: string list_xpath: type: string name: type: string page_attr: type: string page_css: type: string page_xpath: type: string type: object model.Env: properties: name: type: string value: type: string type: object model.Node: properties: _id: type: string create_ts: type: string description: type: string hostname: type: string ip: type: string is_master: description: 前端展示 type: boolean key: description: 用于唯一标识节点,可能是mac地址,可能是ip地址 type: string mac: type: string name: type: string port: type: string status: type: string update_ts: type: string update_ts_unix: type: integer type: object model.Project: properties: _id: type: string create_ts: type: string description: type: string name: type: string spiders: description: 前端展示 items: $ref: '#/definitions/model.Spider' type: array tags: items: type: string type: array update_ts: type: string user_id: type: string username: type: string type: object model.Schedule: properties: _id: type: string create_ts: type: string cron: type: string description: type: string enabled: type: boolean entry_id: type: integer message: type: string name: type: string node_ids: items: type: string type: array nodes: items: $ref: '#/definitions/model.Node' type: array param: type: string run_type: type: string scrapy_log_level: type: string scrapy_spider: type: string spider_id: type: string spider_name: description: 前端展示 type: string status: type: string update_ts: type: string user_id: type: string user_name: type: string type: object model.Spider: properties: _id: description: 爬虫ID type: string cmd: description: 自定义爬虫 type: string col: description: 结果储存位置 type: string config: $ref: '#/definitions/entity.ConfigSpiderData' description: 可配置爬虫配置 type: object create_ts: type: string dedup_field: description: 去重字段 type: string dedup_method: description: 去重方式 type: string display_name: description: 爬虫显示名称 type: string envs: description: 环境变量 items: $ref: '#/definitions/model.Env' type: array file_id: description: GridFS文件ID type: string git_auto_sync: description: Git 是否自动同步 type: boolean git_branch: description: Git 分支 type: string git_has_credential: description: Git 是否加密 type: boolean git_password: description: Git 密码 type: string git_sync_error: description: Git 同步错误 type: string git_sync_frequency: description: Git 同步频率 type: string git_url: description: Git URL type: string git_username: description: Git 用户名 type: string is_dedup: description: 去重 type: boolean is_git: description: Git 设置 type: boolean is_long_task: description: 长任务 type: boolean is_public: description: 是否公开 type: boolean is_scrapy: description: Scrapy 爬虫(属于自定义爬虫) type: boolean is_web_hook: description: Web Hook type: boolean last_run_ts: description: 前端展示 type: string last_status: description: 最后执行状态 type: string latest_tasks: description: 最近任务列表 items: $ref: '#/definitions/model.Task' type: array name: description: 爬虫名称(唯一) type: string project_id: description: 项目ID type: string remark: description: 备注 type: string site: description: 爬虫网站 type: string spider_names: description: 爬虫名称列表 items: type: string type: array src: description: 源码位置 type: string template: description: 可配置爬虫 type: string type: description: 爬虫类别 type: string update_ts: type: string user_id: description: 时间 type: string username: description: 用户名称 type: string web_hook_url: description: Web Hook URL type: string type: object model.Task: properties: _id: type: string cmd: type: string create_ts: type: string error: type: string error_log_count: type: integer finish_ts: type: string log_path: type: string node_id: type: string node_name: type: string param: type: string pid: type: integer result_count: type: integer run_type: type: string runtime_duration: type: number schedule_id: type: string spider_id: type: string spider_name: description: 前端数据 type: string start_ts: type: string status: type: string total_duration: type: number update_ts: type: string user_id: type: string username: type: string wait_duration: type: number type: object model.User: properties: _id: type: string create_ts: type: string email: type: string password: type: string role: type: string setting: $ref: '#/definitions/model.UserSetting' type: object update_ts: type: string user_id: type: string username: type: string type: object model.UserSetting: properties: ding_talk_robot_webhook: type: string enabled_notifications: items: type: string type: array error_regex_pattern: type: string log_expire_duration: type: integer max_error_log: type: integer notification_trigger: type: string wechat_robot_webhook: type: string type: object model.Variable: properties: _id: type: string key: type: string remark: type: string value: type: string type: object routes.SpiderFileReqBody: properties: content: type: string new_path: type: string path: type: string type: object routes.TaskListRequestData: properties: nodeId: type: string pageNum: type: integer pageSize: type: integer scheduleId: type: string spiderId: type: string status: type: string type: object routes.TaskResultsRequestData: properties: pageNum: type: integer pageSize: type: integer type: object routes.UserListRequestData: properties: pageNum: type: integer pageSize: type: integer type: object routes.UserRequestData: properties: email: type: string password: type: string role: type: string username: type: string type: object info: contact: {} license: {} paths: /config_spiders: put: consumes: - application/json description: Put config spider parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider item in: body name: spider required: true schema: $ref: '#/definitions/model.Spider' type: object produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Put config spider tags: - config spider /config_spiders/{id}/config: get: consumes: - application/json description: Get config spider parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Get config spider tags: - config spider post: consumes: - application/json description: Post config spider config parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider item in: body name: spider required: true schema: $ref: '#/definitions/model.Spider' type: object - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Post config spider config tags: - config spider /config_spiders/{id}/spiderfile: post: consumes: - application/json description: Post config spider parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Post config spider tags: - config spider /config_spiders/{id}/upload: post: consumes: - application/json description: Upload config spider parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider item in: body name: spider required: true schema: $ref: '#/definitions/model.Spider' type: object - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Upload config spider tags: - config spider /config_spiders_templates: get: consumes: - application/json description: Get config spider template list parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Get config spider template list tags: - config spider /docs: get: description: Get docs parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get docs tags: - docs /file: get: description: Get file parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get file tags: - file /nodes: get: description: Get nodes parameters: - description: With the bearer started in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get nodes tags: - node /nodes/{id}: delete: description: Delete node parameters: - description: With the bearer started in: header name: Authorization required: true type: string - description: node id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Delete node tags: - node get: description: Get node parameters: - description: With the bearer started in: header name: Authorization required: true type: string - description: id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get node tags: - node post: consumes: - application/json description: Post node parameters: - description: With the bearer started in: header name: Authorization required: true type: string - description: post node in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Post node tags: - node /nodes/{id}/deps: get: description: Get dep list parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: node id in: path name: id required: true type: string - description: language in: query name: lang required: true type: string - description: dep name in: query name: dep_name required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get dep list tags: - system /nodes/{id}/deps/install: post: description: Install dep parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: node id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Install dep tags: - system /nodes/{id}/deps/installed: get: description: Get installed dep list parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: node id in: path name: id required: true type: string - description: language in: query name: lang required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get installed dep list tags: - system /nodes/{id}/deps/uninstall: post: description: Uninstall dep parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: node id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Uninstall dep tags: - system /nodes/{id}/langs: get: description: Get language list parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: node id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get language list tags: - system /nodes/{id}/langs/install: post: description: Install language parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: node id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Install language tags: - system /nodes/{id}/system: get: description: Get system info parameters: - description: With the bearer started in: header name: Authorization required: true type: string - description: node id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get system info tags: - node /nodes/{id}/tasks: get: description: Get tasks on node parameters: - description: With the bearer started in: header name: Authorization required: true type: string - description: node id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get tasks on node tags: - node /projects: get: description: Get projects parameters: - description: With the bearer started in: header name: Authorization required: true type: string - description: projects in: query name: tag required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get projects tags: - project put: consumes: - application/json description: Put project parameters: - description: With the bearer started in: header name: Authorization required: true type: string - description: post project in: body name: p required: true schema: $ref: '#/definitions/model.Project' type: object produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Put project tags: - project /projects/{id}: delete: description: Delete project parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: project id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Delete project tags: - project post: consumes: - application/json description: Post project parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: project id in: path name: id required: true type: string - description: project item in: body name: item required: true schema: $ref: '#/definitions/model.Project' type: object produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Post project tags: - project /projects/tags: get: description: Get projects tags parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get project tags tags: - project /releases/latest: get: description: Get latest release parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get latest release tags: - version /schedules: get: description: Get spider list parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: page num in: query name: page_num type: string - description: page size in: query name: page_size type: string - description: keyword in: query name: keyword type: string - description: project_id in: query name: project_id type: string - description: type in: query name: type type: string - description: sort_key in: query name: sort_key type: string - description: sort_direction in: query name: sort_direction type: string - description: owner_type in: query name: owner_type type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get spider list tags: - spider put: consumes: - application/json description: Put schedule parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: schedule item in: body name: item required: true schema: $ref: '#/definitions/model.Schedule' type: object produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Put schedule tags: - schedule /schedules/{id}: delete: description: Delete schedule parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: schedule id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Delete schedule tags: - schedule get: description: Get schedule by id parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: schedule id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get schedule by id tags: - schedule post: consumes: - application/json description: Post schedule parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: schedule id in: path name: id required: true type: string - description: schedule item in: body name: newItem required: true schema: $ref: '#/definitions/model.Schedule' type: object produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Post schedule tags: - schedule /schedules/{id}/disable: post: consumes: - application/json description: disable schedule parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: schedule id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: disable schedule tags: - schedule /schedules/{id}/enable: post: consumes: - application/json description: enable schedule parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: schedule id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: enable schedule tags: - schedule /setting: get: description: Get setting parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get setting tags: - setting /spiders: post: consumes: - application/json description: delete spider parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: delete spider tags: - spider put: consumes: - application/json description: Put spider parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider item in: body name: spider required: true schema: $ref: '#/definitions/model.Spider' type: object produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Put spider tags: - spider /spiders-cancel: post: consumes: - application/json description: cancel spider parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: cancel spider tags: - spider /spiders-run: post: consumes: - application/json description: run spider parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: run spider tags: - spider /spiders/{id}: delete: description: Delete spider by id parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Delete spider by id tags: - spider get: description: Get spider by id parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: schedule id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get spider by id tags: - spider post: consumes: - application/json description: Post spider parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: schedule id in: path name: id required: true type: string - description: spider item in: body name: item required: true schema: $ref: '#/definitions/model.Spider' type: object produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Post spider tags: - spider /spiders/{id}/copy: post: consumes: - application/json description: Copy spider parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: schedule id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Copy spider tags: - spider /spiders/{id}/dir: get: description: Get spider dir parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string - description: path in: query name: path required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get spider dir tags: - spider /spiders/{id}/file: delete: description: Delete spider file parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string - description: path in: body name: reqBody required: true schema: $ref: '#/definitions/routes.SpiderFileReqBody' type: object produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Delete spider file tags: - spider get: description: Get spider file parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string - description: path in: query name: path required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get spider file tags: - spider post: description: Put spider file parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string - description: path in: body name: reqBody required: true schema: $ref: '#/definitions/routes.SpiderFileReqBody' type: object produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Put spider file tags: - spider put: description: Post spider dir parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string - description: path in: body name: reqBody required: true schema: $ref: '#/definitions/routes.SpiderFileReqBody' type: object produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Post spider dir tags: - spider /spiders/{id}/file/rename: post: description: Rename spider file parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string - description: path in: body name: reqBody required: true schema: $ref: '#/definitions/routes.SpiderFileReqBody' type: object produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Rename spider file tags: - spider /spiders/{id}/file/tree: get: description: Get spider dir parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get spider dir tags: - spider /spiders/{id}/git/reset: post: description: Post spider reset git parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Post spider reset git tags: - spider /spiders/{id}/git/sync: post: description: Post spider sync git parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Post spider sync git tags: - spider /spiders/{id}/publish: post: consumes: - application/json description: Publish spider parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: schedule id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Publish spider tags: - spider /spiders/{id}/schedules: get: description: Get schedules parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get schedules tags: - spider /spiders/{id}/scrapy/items: get: description: Get scrapy spider items parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get scrapy spider items tags: - spider post: description: Post scrapy spider items parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string - description: req data in: body name: reqData required: true schema: items: $ref: '#/definitions/entity.ScrapyItem' type: entity.ScrapyItem produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Post scrapy spider items tags: - spider /spiders/{id}/scrapy/pipelines: get: description: Get scrapy spider pipelines parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get scrapy spider pipelines tags: - spider /spiders/{id}/scrapy/settings: get: description: Get scrapy spider settings parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get scrapy spider settings tags: - spider post: description: Get scrapy spider file parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string - description: req data in: body name: reqData required: true schema: items: $ref: '#/definitions/entity.ScrapySettingParam' type: entity.ScrapySettingParam produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get scrapy spider file tags: - spider /spiders/{id}/scrapy/spider/filepath: get: description: Get scrapy spider file path parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get scrapy spider file path tags: - spider /spiders/{id}/scrapy/spiders: get: description: Get scrapy spider file parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get scrapy spider file tags: - spider put: description: Put scrapy spider file parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Put scrapy spider file tags: - spider /spiders/{id}/stats: get: description: Get spider stats parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get spider stats tags: - spider /spiders/{id}/tasks: get: description: Get task list parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get task list tags: - spider /spiders/{id}/upload: post: consumes: - application/json description: Upload spider by id parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: spider file to upload in: formData name: file required: true type: file - description: spider id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "500": description: Internal Server Error schema: type: json summary: Upload spider by id tags: - spider /stats/home: get: description: Get home stats parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get home stats tags: - version /system/deps/: get: description: Get all dep list parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: language in: path name: lang required: true type: string - description: dep name in: query name: dep_nane required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get all dep list tags: - system /system/deps/{lang}/{dep_name}/json: get: description: Get dep json parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: language in: path name: lang required: true type: string - description: dep name in: path name: dep_name required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get dep json tags: - system /task/{id}: delete: description: Delete task parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: task id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Delete task tags: - task /tasks: delete: description: Delete tasks parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Delete tasks tags: - task get: description: Get task list parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: req data in: body name: data required: true schema: $ref: '#/definitions/routes.TaskListRequestData' type: object produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get task list tags: - task put: description: Put task parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Put task tags: - task /tasks/{id}: get: description: Get task parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: task id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get task tags: - task /tasks/{id}/cancel: post: description: Cancel task parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: task id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Cancel task tags: - task /tasks/{id}/error-log: delete: description: Get task error log parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: task id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get task error log tags: - task /tasks/{id}/log: delete: description: Get task log parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: task id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get task log tags: - task /tasks/{id}/restart: post: description: Restart task parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: task id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Restart task tags: - task /tasks/{id}/results: get: description: Get task list parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: req data in: body name: data required: true schema: $ref: '#/definitions/routes.TaskResultsRequestData' type: object - description: task id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get task list tags: - task /tasks/{id}/results/download: get: description: Get task results parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: task id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get task results tags: - task /tasks_by_status: delete: description: Delete task parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: task status in: query name: status required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Delete task tags: - task /tokens: get: description: token parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get token tags: - token put: description: token parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Put token tags: - token /tokens/{id}: delete: description: Delete token parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: token id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Delete token tags: - token /users: get: description: Get user list parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: data body in: body name: data required: true schema: $ref: '#/definitions/routes.UserListRequestData' type: object produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get user list tags: - token put: description: Put user parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: reqData body in: body name: reqData required: true schema: $ref: '#/definitions/routes.UserRequestData' type: object produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Put user tags: - user /users/{id}: delete: description: Delete user parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: user id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Delete user tags: - user get: description: user parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: user id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get user tags: - user post: description: Post user parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: user body in: body name: item required: true schema: $ref: '#/definitions/model.User' type: object - description: user id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Post user tags: - user /variable: put: description: Put variable parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: reqData body in: body name: variable required: true schema: $ref: '#/definitions/model.Variable' type: object produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Put variable tags: - variable /variable/{id}: delete: description: Delete variable parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: variable id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Delete variable tags: - variable post: description: Post variable parameters: - description: Authorization token in: header name: Authorization required: true type: string - description: reqData body in: body name: variable required: true schema: $ref: '#/definitions/model.Variable' type: object - description: variable id in: path name: id required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Post variable tags: - variable /variables: get: description: Get variable list parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get variable list tags: - variable /version: get: description: Get version parameters: - description: Authorization token in: header name: Authorization required: true type: string produces: - application/json responses: "200": description: OK schema: type: json "400": description: Bad Request schema: type: json summary: Get version tags: - setting swagger: "2.0"