Help Center/ CodeArts Req/ API Reference/ Application Examples/ Example 1: Obtaining the Project List in CodeArts Req
Updated on 2025-05-22 GMT+08:00

Example 1: Obtaining the Project List in CodeArts Req

Scenario

This section uses the test001 user as an example to describe how to use an API to query the project list of the current user.

For details about how to call APIs, see Calling APIs.

Constraints

Ensure that the test001 user has created or participated in a project in CodeArts Req.

Involved API

Query project information of the current user based on the user token.

URI: GET /v4/projects

For details about the API document, see "Querying the Project List".

For details about online API Explorer debugging, see "Querying the Project List."

Procedure

  • Request example
    GET https://excample.com/v4/projects?project_type=scrum&search=ProjectTestCase&offset=0&limit=1
  • Response example
    {
    "projects": [
            {
    "project_num_id": 3844012,
    "project_id": "ec147b681fb64e019a6bcd73ebdf3597",
    "project_name": "ProjectTestCaseYRXl",
    "description": "fdas",
    "created_time": 1600417972000,
    "updated_time": 1600417972000,
    "project_type": "scrum",
    "creator": {
    "user_num_id": 4090,
    "user_id": "665b542eb4c14b53a15ead449f28b0ba",
    "user_name": "test001",
    "domain_id": "70d11a2d7275425689347ec104af2ad8",
    "domain_name": "projectman_l00382124_01",
    "nick_name": "Jim"
                }
            }
        ],
    "total": 48
    }