GET
/
api
/
projects
curl --request GET \
  --url https://api.gnomy.io/api/projects \
  --header 'x-api-key: <api-key>'
{
  "data": [
    {
      "id": "<string>",
      "user_id": "<string>",
      "created_at": "2023-11-07T05:31:56Z",
      "name": "<string>",
      "description": "<string>"
    }
  ],
  "pagination": {
    "page": 123,
    "pageSize": 123,
    "total": 123,
    "totalPages": 123
  }
}

Retrieves a paginated list of projects for the authenticated user.

Authentication

This endpoint requires an API key for authentication. Include your API key in the request headers using the x-api-key header.

Query Parameters

ParameterTypeRequiredDefaultDescription
pagenumberNo1The page number for pagination
pageSizenumberNo10The number of items per page

Response

Success Response (200 OK)

{
  "data": [
    {
      "id": "string",
      "user_id": "string",
      "created_at": "string (ISO date)",
      "name": "string",
      "description": "string"
    }
  ],
  "pagination": {
    "page": 1,
    "pageSize": 10,
    "total": 100,
    "totalPages": 10
  }
}

Error Response (401 Unauthorized)

{
  "error": "Unauthorized"
}

Error Response (500 Internal Server Error)

{
  "error": "Error message"
}

Example

curl -X GET "https://api.gnomy.io/api/projects?page=1&pageSize=20" \
  -H "x-api-key: YOUR_API_KEY"

Authorizations

x-api-key
string
header
required

Query Parameters

page
integer
default:1

The page number for pagination

pageSize
integer
default:10

The number of items per page

Response

200
application/json

Successfully retrieved projects

The response is of type object.

GET
/
api
/
projects
curl --request GET \
  --url https://api.gnomy.io/api/projects \
  --header 'x-api-key: <api-key>'
{
  "data": [
    {
      "id": "<string>",
      "user_id": "<string>",
      "created_at": "2023-11-07T05:31:56Z",
      "name": "<string>",
      "description": "<string>"
    }
  ],
  "pagination": {
    "page": 123,
    "pageSize": 123,
    "total": 123,
    "totalPages": 123
  }
}

Retrieves a paginated list of projects for the authenticated user.

Authentication

This endpoint requires an API key for authentication. Include your API key in the request headers using the x-api-key header.

Query Parameters

ParameterTypeRequiredDefaultDescription
pagenumberNo1The page number for pagination
pageSizenumberNo10The number of items per page

Response

Success Response (200 OK)

{
  "data": [
    {
      "id": "string",
      "user_id": "string",
      "created_at": "string (ISO date)",
      "name": "string",
      "description": "string"
    }
  ],
  "pagination": {
    "page": 1,
    "pageSize": 10,
    "total": 100,
    "totalPages": 10
  }
}

Error Response (401 Unauthorized)

{
  "error": "Unauthorized"
}

Error Response (500 Internal Server Error)

{
  "error": "Error message"
}

Example

curl -X GET "https://api.gnomy.io/api/projects?page=1&pageSize=20" \
  -H "x-api-key: YOUR_API_KEY"

Authorizations

x-api-key
string
header
required

Query Parameters

page
integer
default:1

The page number for pagination

pageSize
integer
default:10

The number of items per page

Response

200
application/json

Successfully retrieved projects

The response is of type object.