Skip to main content

API Spec

Github Copilot Extension (0.0.1)

Download OpenAPI specification:Download

powered by Flasgger

Logging

Logs the event to the database. See Swagger docs for more information.

Logs the event to the database.

Request Body schema: application/json
data
required
object
event
required
string
timestamp
required
number

Responses

Request samples

Content type
application/json
{
  • "data": {
    },
  • "event": "User logged in",
  • "timestamp": 1708401940
}

Retrieve all logs in the database See Swagger docs for more information.

Fetches all logged events from the database.

Responses

Get all logs for a specific user See Swagger docs for more information.

Fetches all logged events associated with a specific user ID.

path Parameters
user_id
required
integer
Example: 12345

The ID of the user whose logs are being retrieved.

Responses

Suggestions

Generate a suggestion based on the provided prompt. See Swagger docs for more information.

Sends a prompt to the locally running Ollama model and returns the generated suggestion.

Request Body schema: application/json
prompt
required
string

Responses

Request samples

Content type
application/json
{
  • "prompt": "def add(a, b):"
}

Response samples

Content type
application/json
{
  • "suggestions": [
    ]
}

Users

Create a new user with first name, last name, email, and password.

Registers a new user with first name, last name, email, and password.

Request Body schema: application/json
email
required
string
first_name
required
string
last_name
required
string
password
required
string

Responses

Request samples

Content type
application/json
{
  • "email": "jaime@example.com",
  • "first_name": "Jaime",
  • "last_name": "Nguyen",
  • "password": "password123"
}

TODO Get a specific user by ID

Retrieves user details based on the provided user ID.

path Parameters
user_id
required
string
Example: 123

Responses