{ "openapi": "3.0.3", "info": { "title": "AB.GL API", "description": "API for link management and URL shortening", "version": "1.0.0", "x-jentic-source-url": "https://abgl.link/api-docs", "contact": {} }, "servers": [ { "url": "https://api.abgl.link" } ], "paths": { "/links": { "get": { "operationId": "listLinks", "summary": "List shortened links", "description": "List shortened links", "security": [ { "apiKey": [] } ], "responses": { "200": { "description": "Successful response", "content": { "application/json": { "schema": { "type": "object" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "tags": [ "links" ] }, "post": { "operationId": "createLink", "summary": "Create a shortened link", "description": "Create a shortened link", "security": [ { "apiKey": [] } ], "responses": { "200": { "description": "Successful response", "content": { "application/json": { "schema": { "type": "object" } } } }, "400": { "description": "Bad request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "requestBody": { "required": true, "content": { "application/json": { "schema": { "type": "object", "properties": { "url": { "type": "string" }, "custom": { "type": "string" } } } } } }, "tags": [ "links" ] } }, "/links/{id}": { "get": { "operationId": "getLink", "summary": "Get link details", "description": "Get link details", "security": [ { "apiKey": [] } ], "responses": { "200": { "description": "Successful response", "content": { "application/json": { "schema": { "type": "object" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "parameters": [ { "name": "id", "in": "path", "required": true, "schema": { "type": "string" } } ], "tags": [ "links" ] }, "delete": { "operationId": "deleteLink", "summary": "Delete a link", "description": "Delete a link", "security": [ { "apiKey": [] } ], "responses": { "200": { "description": "Successful response", "content": { "application/json": { "schema": { "type": "object" } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } } } }, "parameters": [ { "name": "id", "in": "path", "required": true, "schema": { "type": "string" } } ], "tags": [ "links" ] } } }, "components": { "securitySchemes": { "apiKey": { "type": "apiKey", "in": "header", "name": "Authorization" } }, "schemas": { "ErrorResponse": { "type": "object", "properties": { "error": { "type": "string", "description": "Error message" }, "code": { "type": "string", "description": "Error code" } }, "required": [ "error" ] } } }, "tags": [ { "name": "links" } ] }