Ana içeriğe geç

List Projects

Endpoint

GET /apiops/projects/

Authentication

Requires a Personal API Access Token.

Authorization: Bearer YOUR_TOKEN

Request

Headers

HeaderValueRequired
AuthorizationBearer {token}Yes

Path Parameters

None

Query Parameters

None

Response

Success Response (200 OK)

{
"status": "SUCCESS",
"resultList": [
{
"id": "507f1f77bcf86cd799439011",
"name": "default",
"description": "description text",
"relativePath": "/default",
"enableRelativePath": true,
"tags": ["core"]
},
{
"id": "507f1f77bcf86cd799439012",
"name": "MyProject",
"description": "My project description",
"relativePath": "/my-project",
"enableRelativePath": false,
"tags": []
}
],
"resultCount": 2
}

Response Fields

FieldTypeDescription
statusstringResponse status: SUCCESS or FAILURE
resultListarrayList of project objects
resultCountintegerTotal number of projects returned

Project Object Fields

FieldTypeDescription
idstringUnique project identifier
namestringProject name
descriptionstringProject description
relativePathstringRelative path prefix configured for the project
enableRelativePathbooleanWhether the relative path is enabled for routing
tagsarrayList of tag strings assigned to the project

EnumStatus

  • SUCCESS - Operation successful
  • FAILURE - Operation failed

Error Response (401 Unauthorized)

{
"status": "FAILURE",
"resultMessage": "Token is not valid!"
}

Causes

  • Missing or invalid Authorization header
  • Token expired or revoked
  • Invalid token format

Error Response (500 Internal Server Error)

{
"status": "FAILURE",
"resultMessage": "An unexpected error occurred"
}

cURL Example

curl -X GET \
"https://demo.apinizer.com/apiops/projects/" \
-H "Authorization: Bearer YOUR_TOKEN"

Full JSON Body Example

This endpoint does not require a request body.

Notes and Warnings

  • Filtered Results: Only projects where the user is a member are returned
  • Permissions: Project access is based on user membership and roles
  • Empty List: If the user has no projects, an empty resultList is returned
  • Case Sensitivity: Project names are case-sensitive