jobs-monorepo/services/api/pkg/swagger/docs.go
2025-12-18 12:25:07 +05:00

401 lines
13 KiB
Go

// Package swagger Code generated by swaggo/swag. DO NOT EDIT
package swagger
import "github.com/swaggo/swag"
const docTemplate = `{
"schemes": {{ marshal .Schemes }},
"swagger": "2.0",
"info": {
"description": "{{escape .Description}}",
"title": "{{.Title}}",
"contact": {},
"version": "{{.Version}}"
},
"host": "{{.Host}}",
"basePath": "{{.BasePath}}",
"paths": {
"/jobs": {
"get": {
"description": "Gets all jobs with the provided specifications",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"jobs"
],
"summary": "Gets all jobs",
"parameters": [
{
"type": "string",
"description": "Location filter",
"name": "location",
"in": "query"
},
{
"type": "string",
"description": "Keywords filter (searches title and company)",
"name": "keywords",
"in": "query"
},
{
"type": "string",
"description": "Full/Part time filter",
"name": "fwt",
"in": "query"
},
{
"enum": [
0,
1,
2,
3,
4,
5,
6,
7
],
"type": "integer",
"description": "Job provider (LinkedIn=0, Indeed=1, Glassdoor=2, Bayt=3, TokyoDev=4, JapanDev=5, Google=6, HiringCafe=7)",
"name": "provider",
"in": "query"
},
{
"type": "integer",
"description": "Page number",
"name": "pageNumber",
"in": "query"
},
{
"type": "integer",
"description": "Number of elements",
"name": "pageSize",
"in": "query"
}
],
"responses": {
"201": {
"description": "Successfully retrieved jobs",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"400": {
"description": "Invalid request data",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"500": {
"description": "Internal server error",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
}
},
"post": {
"description": "Creates a new job with the provided specifications",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"jobs"
],
"summary": "Create a new job",
"parameters": [
{
"description": "Job creation data",
"name": "job",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/ports.CreateJobCommand"
}
}
],
"responses": {
"201": {
"description": "Successfully created job",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"400": {
"description": "Invalid request data",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"500": {
"description": "Internal server error",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
}
}
},
"/jobs/analysis": {
"get": {
"description": "Retrieves all job analysis results from the database",
"produces": [
"application/json"
],
"tags": [
"jobs"
],
"summary": "Get all job analysis results",
"responses": {
"200": {
"description": "List of job analysis results",
"schema": {
"type": "array",
"items": {
"$ref": "#/definitions/domain.JobAnalysisResult"
}
}
},
"500": {
"description": "Internal server error",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
}
}
},
"/jobs/analysis/top-matches": {
"get": {
"description": "Retrieves jobs with high analysis match scores",
"produces": [
"application/json"
],
"tags": [
"jobs"
],
"summary": "Get top matching jobs",
"parameters": [
{
"type": "integer",
"description": "Minimum match score (default: 70)",
"name": "min_score",
"in": "query"
}
],
"responses": {
"200": {
"description": "List of top matching job analysis results",
"schema": {
"type": "array",
"items": {
"$ref": "#/definitions/domain.JobAnalysisResult"
}
}
},
"400": {
"description": "Invalid minimum score",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"500": {
"description": "Internal server error",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
}
}
},
"/jobs/{id}/analysis": {
"get": {
"description": "Retrieves the analysis result for a specific job",
"produces": [
"application/json"
],
"tags": [
"jobs"
],
"summary": "Get job analysis result by job ID",
"parameters": [
{
"type": "integer",
"description": "Job ID",
"name": "id",
"in": "path",
"required": true
}
],
"responses": {
"200": {
"description": "Job analysis result",
"schema": {
"$ref": "#/definitions/domain.JobAnalysisResult"
}
},
"400": {
"description": "Invalid job ID",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"404": {
"description": "Analysis result not found",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
},
"500": {
"description": "Internal server error",
"schema": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
}
}
}
},
"definitions": {
"domain.JobAnalysisResult": {
"type": "object",
"properties": {
"analysisResult": {
"type": "string"
},
"analyzedAt": {
"type": "string"
},
"id": {
"type": "integer",
"format": "int64"
},
"jobID": {
"type": "integer",
"format": "int64"
},
"keySkills": {
"type": "array",
"items": {
"type": "string"
}
},
"matchScore": {
"type": "integer"
},
"missingSkills": {
"type": "array",
"items": {
"type": "string"
}
},
"recommendations": {
"type": "string"
}
}
},
"domain.JobProvider": {
"type": "integer",
"enum": [
0,
1,
2,
3,
4,
5,
6,
7
],
"x-enum-varnames": [
"LinkedIn",
"Indeed",
"Glassdoor",
"Bayt",
"TokyoDev",
"JapanDev",
"Google",
"HiringCafe"
]
},
"ports.CreateJobCommand": {
"type": "object",
"properties": {
"fwt": {
"type": "string"
},
"keywords": {
"type": "string"
},
"location": {
"type": "string"
},
"numPages": {
"type": "integer"
},
"provider": {
"$ref": "#/definitions/domain.JobProvider"
}
}
}
}
}`
// SwaggerInfo holds exported Swagger Info so clients can modify it
var SwaggerInfo = &swag.Spec{
Version: "1.0",
Host: "",
BasePath: "/",
Schemes: []string{},
Title: "Jobs Scraper API",
Description: "API for managing job scraping operations",
InfoInstanceName: "swagger",
SwaggerTemplate: docTemplate,
LeftDelim: "{{",
RightDelim: "}}",
}
func init() {
swag.Register(SwaggerInfo.InstanceName(), SwaggerInfo)
}