---
title: "Retrieve the list of all service accounts in the current organization."
method: GET
path: "/organizations/iam/service_accounts"
---

# Retrieve the list of all service accounts in the current organization.

`GET /organizations/iam/service_accounts`

## Request

- Base URL: `https://api.border0.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.border0.com/organizations/iam/service_accounts`
- Auth: API key in header `Authorization`

## Response `200`

OK

- ServiceaccountPaginatedServiceAccount
  - `list` ServiceaccountSlim[]
    - `access_graph` SerializerAccessGraph
      - `edges` SerializerAccessGraphEdge[]
        - `dst_node_id` string
        - `edge_id` string
        - `src_node_id` string
      - `nodes` SerializerAccessGraphNode[]
        - `label` string
        - `metadata` object
        - `node_id` string
        - `resource_id` string
        - `resource_type` 'user' | 'group' | 'service account' | 'policy' | 'socket'
        - `warnings` SerializerWarning[]
          - `args` object
          - `code` string
      - `principal_resource_type` 'user' | 'group' | 'service account' | 'policy' | 'socket'
    - `active` boolean
    - `created_at` string
    - `description` string
    - `directory_service` SerializerDirectoryService
      - `display_name` string
      - `id` string
      - `service_type` string
    - `last_seen_at` string
    - `name` string
    - `role` string
    - `service_account_id` string
    - `updated_at` string
  - `pagination` ModelsPaginationResult
    - `actual_page_size` integer
    - `current_page` integer
    - `next_page` integer
    - `records_per_page` integer
    - `total_pages` integer
    - `total_records` integer

## Other responses

- `400`: Bad Request
- `403`: Forbidden
- `500`: Internal Server Error

---

[API](https://skmtc.dev/border0/apis/border0-api.md) - [All operations](https://skmtc.dev/border0/apis/border0-api/llms.txt) - [OpenAPI document](https://skmtc.dev/border0/apis/border0-api/revisions/f0ccef7418d8?raw)
