Updated on 2026-10-27 GMT+08:00

Obtaining the Agency List

Function

This API is used to obtain the list of agencies created for FunctionGraph.

Calling Method

For details, see Calling APIs.

Authorization Information

Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions. For details about the required permissions, see Permissions Policies and Supported Actions.

URI

GET /v2/{project_id}/fgs/service-trusted-agencies

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Parameter description:

Project ID. For details, see Obtaining a Project ID.

Constraints:

None

Value range:

32 characters, including letters and digits.

Default value:

None

Table 2 Query Parameters

Parameter

Mandatory

Type

Description

marker

No

String

Definition

Start position of the current query.

Constraints

Only digits are allowed. The value is a string of 1 to 64 characters.

Range

N/A

Default Value

'0'

limit

No

String

Definition

Maximum number of data records that can be returned in the current query.

Constraints

Only digits are allowed. The value is a string of 1 to 64 characters.

Range

N/A.

Default Value

'100'

Request Parameters

Table 3 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

Parameter description:

User token.

The token can be obtained by calling the IAM API. The value of X-Subject-Token in the response header is the user token.

Constraints:

None

Value range:

None

Default value:

None

Content-Type

No

String

Parameter description:

Specifies the type (or format) of the message body.

Constraints:

None

Value range:

Only application/json is supported.

Default value:

application/json

Response Parameters

Status code: 200

Table 4 Response body parameters

Parameter

Type

Description

[items]

Array of TrustAgencyItem objects

Definition

Response body for obtaining the agency list.

Range

N/A

Table 5 TrustAgencyItem

Parameter

Type

Description

name

String

Definition

Agency name.

Range

0 to 64

expire_time

String

Definition

Expiration time of the agency. The value null indicates that the agency has unlimited validity.

Range

The value is a UTC time in the "YYYY-MM-DDTHH:mm:ss.ssssss" format, for example, 2023-06-28T08:56:33.710000.

Status code: 401

Table 6 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Status code: 403

Table 7 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Status code: 500

Table 8 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Example Requests

Obtaining the agency list

GET /v2/{project_id}/fgs/service-trusted-agencies

Example Responses

Status code: 200

[ {
  "name" : "fg-agency-a",
  "expire_time" : null
}, {
  "name" : "fg-agency-b",
  "expire_time" : null
}, {
  "name" : "fg-agency-c",
  "expire_time" : null
} ]

Status Codes

Status Code

Description

200

ok

401

Unauthorized.

403

Forbidden.

500

Internal server error.

Error Codes

See Error Codes.