Skip to main content

Get Resource

Retrieves details for a specific cloud resource by ID.

Request

GET /resources/{id}

Authentication

Requires one of:

  • Bearer JWT Token with ORG_ADMIN role
  • API Key with resources:read scope
Authorization: Bearer <access_token>

or

Authorization: ApiKey <api_key>

Path Parameters

ParameterTypeRequiredDescription
idUUIDYesResource unique identifier

Response

Success Response

Status Code: 200 OK

Response Body:

{
"id": "550e8400-e29b-41d4-a716-446655440000",
"name": "Production API Gateway",
"credentialId": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
"credentialName": "AWS Production Account",
"provider": "AWS",
"resourceType": "SECURITY_GROUP",
"resourceIdentifier": "sg-0abc123def456",
"region": "eu-central-1",
"config": {
"port": 443,
"protocol": "tcp"
},
"isActive": true,
"lastVerifiedAt": "2026-02-18T10:30:00Z",
"createdAt": "2026-01-15T08:00:00Z",
"updatedAt": "2026-02-18T10:30:00Z"
}

Response Fields

FieldTypeDescription
idUUIDUnique resource identifier
namestringHuman-readable resource name
credentialIdUUIDID of linked cloud credential
credentialNamestringName of linked cloud credential
providerstringCloud provider: AWS, GCP, AZURE, or APISIX
resourceTypestringType of resource (e.g., SECURITY_GROUP)
resourceIdentifierstringCloud provider's resource ID (e.g., sg-abc123)
regionstringCloud region (optional, provider-specific)
configobjectResource-specific configuration (e.g., ports, protocols)
isActivebooleanWhether resource is currently active and verified
lastVerifiedAtstring (ISO 8601)Timestamp of last successful verification (null if never verified)
createdAtstring (ISO 8601)Resource creation timestamp
updatedAtstring (ISO 8601)Last update timestamp

Error Responses

Status CodeErrorDescription
401 UnauthorizedUNAUTHORIZEDMissing or invalid authentication token/API key
403 ForbiddenFORBIDDENUser lacks ORG_ADMIN role or API key lacks resources:read scope
404 Not FoundRESOURCE_NOT_FOUNDResource with specified ID does not exist or does not belong to your organization
429 Too Many RequestsRATE_LIMIT_EXCEEDEDRate limit exceeded
500 Internal Server ErrorINTERNAL_ERRORServer error occurred

Error Response Example

{
"error": "RESOURCE_NOT_FOUND",
"message": "Resource with ID 550e8400-e29b-41d4-a716-446655440000 not found",
"timestamp": "2026-02-18T11:15:00Z"
}

Example

Request

curl -X GET https://api.entryguard.io/api/v1/resources/550e8400-e29b-41d4-a716-446655440000 \
-H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..." \
-H "Content-Type: application/json"

Using API Key

curl -X GET https://api.entryguard.io/api/v1/resources/550e8400-e29b-41d4-a716-446655440000 \
-H "Authorization: ApiKey eg_live_1a2b3c4d5e6f7g8h9i0j" \
-H "Content-Type: application/json"

Response

{
"id": "550e8400-e29b-41d4-a716-446655440000",
"name": "Production API Gateway",
"credentialId": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
"credentialName": "AWS Production Account",
"provider": "AWS",
"resourceType": "SECURITY_GROUP",
"resourceIdentifier": "sg-0abc123def456",
"region": "eu-central-1",
"config": {
"port": 443,
"protocol": "tcp"
},
"isActive": true,
"lastVerifiedAt": "2026-02-18T10:30:00Z",
"createdAt": "2026-01-15T08:00:00Z",
"updatedAt": "2026-02-18T10:30:00Z"
}

Notes

  • Resources are scoped to your organization - you can only access resources belonging to your organization
  • The response includes the linked credential's name but not its secrets