gateway
register external connectors, discover, query, invoke, config
A collection of operations for using company data connectors from app code. Everything that passes through the gateway is here — connector and resource reads, session issuance, safe query and invoke. Every call is governed by grants (permissions) and presets (allowed actions), with safeguards such as scoped grants and row/column access policies layered on top. The flow of connecting a connector for the first time and getting it approved is in the connecting company data guide.
14 operations — register external connectors, discover, query, invoke, config
Scoped grants · access policies · EXPLAIN
query·invoke 계열 op 를 부르기 전에 알아야 하는 안전장치 규칙이다 (spec 168·169·171·172).
- grant 의 4번째 축 —
scope_resource_paths(spec 172): grant 는 subject×connector×preset 에 범위 축이 더해진 4축이다.schema/table문자열 배열(최대 200개, 중복 제거)로 "어디까지" 를 지정하며, 빈 배열/생략 = 커넥터 전체(기존 동작). 생성 시 지정하거나 tenant_admin 이PUT /api/v1/tenants/{tenantID}/grants/{grantID}/scope(authorizationPutApiV1TenantsByTenantIDGrantsByGrantIDScope) 로 통째 교체한다. 회수·만료된 grant 는 409. - 범위 지정 grant 의 자유 쿼리 거부 (spec 172): 판정은 fail-closed — 대상을 확정할 수 없으면 거부다. 자유 SQL(
/gateway/query), RESTinvoke, 파일file-invoke,database미지정document-invoke는 403scope_requires_target. 대상이 명시된 호출(document-invoke의 database+collection)은 목록 안이면 허용, 밖이면 403scope_out_of_range. 범위가 빈 grant 는 모든 경로에서 종전과 동일하다. - 행·열 접근 정책의 스코프 (spec 169·171): 정책(access-policy)은
resource_path(적용 대상schema/table— 비면 커넥터 전체)와connector_id(소속 커넥터 — 비면 커넥터 무관)를 가진다. 관리 표면은/api/v1/tenants/{tenantID}/access-policiesCRUD 이고, 활성 grant 가 참조 중인 정책 삭제는 409policy_in_use(spec 168 — 지우면 그 grant 의 쿼리가 전부 fail-closed 거부되기 때문). - EXPLAIN action (spec 168): kind=db preset 의 action vocabulary 는 SELECT/INSERT/UPDATE/DELETE 에
EXPLAIN이 추가됐다. EXPLAIN 은 read-only 로 분류돼 READ ONLY 트랜잭션에서 실행되고,EXPLAIN ANALYZE로 위장한 쓰기는 엔진이 거부한다. 기본 "Read Only" preset 은 backfill 로 EXPLAIN 을 갖는다 (SELECT 없는 preset 은 대상 아님).
GET /api/v1/tenants/{tenantID}/connectors
gatewayGetApiV1TenantsByTenantIDConnectors
- 호출 권한: tenant_admin 테넌트에 등록된 connector 목록을 조회한다.
| Language | Call |
|---|---|
| node | not in @ax-hub/sdk — use admin.tenant(x).connectors.list in the ops package @ax-hub/admin-sdk |
| go | client.Gateway().GatewayGetApiV1TenantsByTenantIDConnectors(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayGetApiV1TenantsByTenantIDConnectors(pathParams, query, body) — async: gatewayGetApiV1TenantsByTenantIDConnectorsAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayGetApiV1TenantsByTenantIDConnectors(pathParams, query, body) — suspend |
| python | client.gateway.gateway_get_api_v1_tenants_by_tenant_id_connectors(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_get_api_v1_tenants_by_tenant_id_connectors(path_params: …, query: …, body: …) |
| generic | request("gatewayGetApiV1TenantsByTenantIDConnectors", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
Query parameters — pass via query (string values)
| Name | Type | Description |
|---|---|---|
enabled_only | boolean | true 면 enabled=true 만 |
Response — 200 · OK
Array response → the SDK wraps it as {"value": [...]}. Element fields:
| Name | Type | Description |
|---|---|---|
id | string | connector UUID |
name | string | unique connector 이름 |
kind | string | db / api |
engine | string | postgres / mysql / mssql / oracle / clickhouse / vertica / rest-api + wire-compatible alias |
enabled | boolean | 관리자 활성 토글. false 면 커넥터가 쓰이지 않아요 |
status | string | 표시용 상태 배지: active(정상) / auth_expired(재인증 필요) / offline(에이전트 연결 끊김) / disabled |
authStatus (wire: auth_status) | string | OAuth refresh_token 사용 가능 여부: active / auth_expired. direct DB 커넥터는 항상 active |
appId (wire: app_id) | string | "axhub 앱 DB" 커넥터의 원본 앱 UUID. 일반 커넥터는 생략 |
classification | array<string> | 자유 태그 |
config | object | engine 별 설정 (credential 제외) |
description | string | admin 메모 |
lastDiscoveredAt (wire: last_discovered_at) | string | 마지막 발견 시각 |
tenantId (wire: tenant_id) | string | 소속 tenant UUID |
createdAt (wire: created_at) | string | |
updatedAt (wire: updated_at) | string |
Error statuses: 400 401 403 500 — Error handling
GET /api/v1/tenants/{tenantID}/connectors/{connectorID}
gatewayGetApiV1TenantsByTenantIDConnectorsByConnectorID
- 호출 권한: tenant_admin
| Language | Call |
|---|---|
| node | not in @ax-hub/sdk — use admin.tenant(x).connectors.get in the ops package @ax-hub/admin-sdk |
| go | client.Gateway().GatewayGetApiV1TenantsByTenantIDConnectorsByConnectorID(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayGetApiV1TenantsByTenantIDConnectorsByConnectorID(pathParams, query, body) — async: gatewayGetApiV1TenantsByTenantIDConnectorsByConnectorIDAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayGetApiV1TenantsByTenantIDConnectorsByConnectorID(pathParams, query, body) — suspend |
| python | client.gateway.gateway_get_api_v1_tenants_by_tenant_id_connectors_by_connector_id(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_get_api_v1_tenants_by_tenant_id_connectors_by_connector_id(path_params: …, query: …, body: …) |
| generic | request("gatewayGetApiV1TenantsByTenantIDConnectorsByConnectorID", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
connectorID required | string | connector UUID |
Response — 200 · OK
| Name | Type | Description |
|---|---|---|
classification | array<string> | Classification 은 자유 태그. |
config | object | Config 는 engine 별 설정 (credential 제외). |
createdAt (wire: created_at) | string | |
description | string | Description 은 admin 메모. |
enabled | boolean | |
engine | string | Engine 은 postgres / mysql / mssql / oracle / clickhouse / vertica / rest-api + mysql wire-compatible alias (mariadb / tidb / singlestore) + postgres wire-compatible alias (cockroachdb / yugabytedb / redshift / greenplum / spanner) + oracle alias (tibero). alias 는 UI / catalog 식별만 별, driver / discovery 동일. Aurora / Azure 같은 cloud-managed wrapper 는 host 만 다른 같은 product 라 별도 카드 없이 mysql / postgres / mssql 사용. |
id | string | ID 는 connector UUID. |
kind | string | Kind 는 db / api. |
lastDiscoveredAt (wire: last_discovered_at) | string | LastDiscoveredAt 는 마지막 발견 시각. |
name | string | Name 은 unique connector 이름. |
tenantId (wire: tenant_id) | string | TenantID 는 소속 tenant UUID. |
updatedAt (wire: updated_at) | string |
Error statuses: 400 401 403 404 500 — Error handling
POST /api/v1/tenants/{tenantID}/connectors/{connectorID}/discover
gatewayPostApiV1TenantsByTenantIDConnectorsByConnectorIDDiscover
관리자가 등록 직후 5분 cron 안 기다리고 즉시 스키마/테이블/컬럼을 발견시킨다. 응답으로 발견된 tables/columns 카운트 + schemas + 일부 preview 를 반환.
- 호출 권한: tenant_admin
- 부수 효과: 발견 성공 시 connectors.last_discovered_at 갱신, 새 path INSERT, 사라진 path SoftDelete
- REST connector 등 discoverer 없는 engine 은 zero-value 응답 (정상 200)
| Language | Call |
|---|---|
| node | not in @ax-hub/sdk — use admin.tenant(x).connectors.discover in the ops package @ax-hub/admin-sdk |
| go | client.Gateway().GatewayPostApiV1TenantsByTenantIDConnectorsByConnectorIDDiscover(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayPostApiV1TenantsByTenantIDConnectorsByConnectorIDDiscover(pathParams, query, body) — async: gatewayPostApiV1TenantsByTenantIDConnectorsByConnectorIDDiscoverAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayPostApiV1TenantsByTenantIDConnectorsByConnectorIDDiscover(pathParams, query, body) — suspend |
| python | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_connectors_by_connector_id_discover(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_connectors_by_connector_id_discover(path_params: …, query: …, body: …) |
| generic | request("gatewayPostApiV1TenantsByTenantIDConnectorsByConnectorIDDiscover", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
connectorID required | string | connector UUID |
Response — 200 · OK
| Name | Type | Description |
|---|---|---|
columnsCount (wire: columns_count) | integer | ColumnsCount 는 active 컬럼 row 수 (sweep 후 재집계). |
lastDiscoveredAt (wire: last_discovered_at) | string | LastDiscoveredAt 는 connectors.last_discovered_at 갱신 시각. discoverer 미지원 engine (REST 등) 면 null. |
preview | array<object> | Preview 는 발견된 table 일부 (최대 20개) — UI 카드 미리보기용. |
schemas | array<string> | Schemas 는 발견된 스키마(또는 database) 이름 목록. |
tablesCount (wire: tables_count) | integer | TablesCount 는 이번 sweep 에서 engine 이 보고한 table 수. |
Error statuses: 400 401 403 404 500 — Error handling
GET /api/v1/tenants/{tenantID}/connectors/{connectorID}/resources
gatewayGetApiV1TenantsByTenantIDConnectorsByConnectorIDResources
- 호출 권한: tenant_admin
관리자가 grant 와 무관하게 connector 의 모든 active resource 를
조회한다. 사용자 면 (
/me/connectors/{cID}/resources) 와 동일한 응답 shape 이지만 grant 체크 없음 — 운영자 / 관리 콘솔의 카탈로그 조회용. - limit (1~500, 기본 100) · offset · q (name 부분일치) · parent_id · roots_only
| Language | Call |
|---|---|
| node | not in @ax-hub/sdk — use admin.tenant(x).connectors.resources in the ops package @ax-hub/admin-sdk |
| go | client.Gateway().GatewayGetApiV1TenantsByTenantIDConnectorsByConnectorIDResources(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayGetApiV1TenantsByTenantIDConnectorsByConnectorIDResources(pathParams, query, body) — async: gatewayGetApiV1TenantsByTenantIDConnectorsByConnectorIDResourcesAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayGetApiV1TenantsByTenantIDConnectorsByConnectorIDResources(pathParams, query, body) — suspend |
| python | client.gateway.gateway_get_api_v1_tenants_by_tenant_id_connectors_by_connector_id_resources(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_get_api_v1_tenants_by_tenant_id_connectors_by_connector_id_resources(path_params: …, query: …, body: …) |
| generic | request("gatewayGetApiV1TenantsByTenantIDConnectorsByConnectorIDResources", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
connectorID required | string | connector UUID |
Query parameters — pass via query (string values)
| Name | Type | Description |
|---|---|---|
limit | integer | 페이지 크기 (기본 100, 1~500 clamp) |
offset | integer | 오프셋 (기본 0) |
q | string | name 부분일치 필터 |
parent_id | string | 부모 리소스 UUID — 주면 그 직계 자식 전체를 페이징 없이 반환 (limit/offset/q 무시) |
roots_only | boolean | true 면 최상위(테이블/엔드포인트)만 페이징 — 한 테이블의 컬럼이 페이지 경계에 잘리지 않아요 |
Response — 200 · OK
Paginated response { items: [...], total, next_cursor } — next_cursor is omitted on the last page. items element fields:
| Name | Type | Description |
|---|---|---|
attributes | object | |
classification | array<string> | |
connectorId (wire: connector_id) | string | |
createdAt (wire: created_at) | string | |
id | string | |
kind | string | |
name | string | |
parentId (wire: parent_id) | string | |
path | string | |
tenantId (wire: tenant_id) | string | |
updatedAt (wire: updated_at) | string |
Error statuses: 400 401 403 500 — Error handling
POST /api/v1/tenants/{tenantID}/gateway/document-invoke
gatewayPostApiV1TenantsByTenantIDGatewayDocumentInvoke
MongoDB connector 의 op 를 실행한다.
- 호출 권한: tenant_member (session 의 grant 보유 필요)
- 입력: session_id · op (find/insertOne 등) · collection · 기타 op-별 필드
- 권한: op → SQL action 매핑 (find→SELECT, insertOne→INSERT 등) 후 preset.Allows 체크 (spec 039 §R2)
- 부수 효과: audit emit (TypeAPICall), connector pool 캐시
- 범위 지정 grant 는 대상(database/collection)이 허용 목록 안이면 허용, 밖이면 403
scope_out_of_range.database미지정 등 대상 미상이면 403scope_requires_target(spec 172)
| Language | Call |
|---|---|
| node | sdk.tenant(tenantId).gateway.documentInvoke(…) — 인자·반환 타입은 패키지의 TypeScript 정의 참조 |
| go | client.Gateway().GatewayPostApiV1TenantsByTenantIDGatewayDocumentInvoke(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayPostApiV1TenantsByTenantIDGatewayDocumentInvoke(pathParams, query, body) — async: gatewayPostApiV1TenantsByTenantIDGatewayDocumentInvokeAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayPostApiV1TenantsByTenantIDGatewayDocumentInvoke(pathParams, query, body) — suspend |
| python | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_gateway_document_invoke(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_gateway_document_invoke(path_params: …, query: …, body: …) |
| generic | request("gatewayPostApiV1TenantsByTenantIDGatewayDocumentInvoke", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
Request body — pass via body, wire keys (snake_case) as-is
| Name | Type | Description |
|---|---|---|
collection | string | |
database | string | |
document | object | |
documents | array<any> | |
field | string | |
filter | object | |
limit | integer | |
op | string | |
pipeline | array<any> | |
projection | object | |
session_id | string | |
skip | integer | |
sort | object | |
update | object |
Response — 200 · 실행 결과
| Name | Type | Description |
|---|---|---|
count | integer | |
deletedCount (wire: deleted_count) | integer | |
distinct | array<any> | |
documents | array<object> | |
insertedCount (wire: inserted_count) | integer | |
insertedIds (wire: inserted_ids) | array<any> | |
matchedCount (wire: matched_count) | integer | |
modifiedCount (wire: modified_count) | integer | |
op | string |
Error statuses: 400 401 403 404 500 — Error handling
POST /api/v1/tenants/{tenantID}/gateway/file-invoke
gatewayPostApiV1TenantsByTenantIDGatewayFileInvoke
Google Drive connector 의 file action 을 실행한다.
- 호출 권한: tenant_member (session 의 grant 보유 필요)
- 입력: session_id · action (file:list|file:get|file:search) · 기타 action-별 필드
- 권한: action 그대로 preset.Allows 체크 — native vocab (SQL 매핑 X)
- 응답: Drive API raw shape (id, name, mimeType, size, modifiedTime, parents, webViewLink). 본문 stream X.
- 부수 효과: audit emit (TypeAPICall). refresh_token revoke 시 connector auth_status='auth_expired' 전이.
- 범위 지정 grant 는 이 호출을 거부한다 (파일은 테이블 대상이 아님) — 403
scope_requires_target(spec 172)
| Language | Call |
|---|---|
| node | not provided |
| go | client.Gateway().GatewayPostApiV1TenantsByTenantIDGatewayFileInvoke(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayPostApiV1TenantsByTenantIDGatewayFileInvoke(pathParams, query, body) — async: gatewayPostApiV1TenantsByTenantIDGatewayFileInvokeAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayPostApiV1TenantsByTenantIDGatewayFileInvoke(pathParams, query, body) — suspend |
| python | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_gateway_file_invoke(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_gateway_file_invoke(path_params: …, query: …, body: …) |
| generic | request("gatewayPostApiV1TenantsByTenantIDGatewayFileInvoke", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
Request body — pass via body, wire keys (snake_case) as-is
| Name | Type | Description |
|---|---|---|
action | string | Action 은 file:list / file:get / file:search 중 하나. |
file_id | string | FileID 는 file:get 의 대상. |
parent_folder_id | string | ParentFolderID 는 file:list 의 parent. 비우면 Shared Drive root. |
q | string | Q 는 file:search 의 Drive query string. |
session_id | string | SessionID 는 사전 발급된 gateway session id. |
Response — 200 · OK
| Name | Type | Description |
|---|---|---|
action | string | Action 은 file:list / file:get / file:search 중 하나. |
file | object | File 은 file:get 의 단건 결과. |
files | array<object> | Files 는 file:list / file:search 의 결과 배열. |
Error statuses: 400 401 403 404 500 503 — Error handling
POST /api/v1/tenants/{tenantID}/gateway/invoke
gatewayPostApiV1TenantsByTenantIDGatewayInvoke
5단계: authz → policy in → engine.Invoke → policy out → audit.
- 호출 권한: tenant_member
- 범위 지정 grant 는 이 호출을 거부한다 (REST 경로는 테이블 대상을 명시할 수 없음) — 403
scope_requires_target(spec 172)
| Language | Call |
|---|---|
| node | sdk.tenant(tenantId).gateway.invoke(…) — 인자·반환 타입은 패키지의 TypeScript 정의 참조 |
| go | client.Gateway().GatewayPostApiV1TenantsByTenantIDGatewayInvoke(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayPostApiV1TenantsByTenantIDGatewayInvoke(pathParams, query, body) — async: gatewayPostApiV1TenantsByTenantIDGatewayInvokeAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayPostApiV1TenantsByTenantIDGatewayInvoke(pathParams, query, body) — suspend |
| python | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_gateway_invoke(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_gateway_invoke(path_params: …, query: …, body: …) |
| generic | request("gatewayPostApiV1TenantsByTenantIDGatewayInvoke", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
Request body — pass via body, wire keys (snake_case) as-is
| Name | Type | Description |
|---|---|---|
body | array<integer> | |
headers | object | |
method | string | |
path | string | |
session_id | string |
Response — 200 · OK
| Name | Type | Description |
|---|---|---|
body | array<integer> | |
headers | object | |
statusCode (wire: status_code) | integer |
Error statuses: 400 401 403 404 500 — Error handling
POST /api/v1/tenants/{tenantID}/gateway/query
gatewayPostApiV1TenantsByTenantIDGatewayQuery
5단계: authz → policy in → engine.Execute → policy out → audit.
- 호출 권한: tenant_member
- 입력: session_id · sql · params? · action?
- 부수 효과: audit query emit (allow/deny/error)
- action 은 preset 의 kind=db vocab (SELECT/INSERT/UPDATE/DELETE/
EXPLAIN) 로 판정한다. EXPLAIN 은 read-only 분류 — READ ONLY 트랜잭션에서 실행 (spec 168) - 범위 지정 grant(
scope_resource_paths비어있지 않음)는 자유 SQL 을 거부한다 — 403scope_requires_target(spec 172)
| Language | Call |
|---|---|
| node | sdk.tenant(tenantId).gateway.query.run(…) — 인자·반환 타입은 패키지의 TypeScript 정의 참조 |
| go | client.Gateway().GatewayPostApiV1TenantsByTenantIDGatewayQuery(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayPostApiV1TenantsByTenantIDGatewayQuery(pathParams, query, body) — async: gatewayPostApiV1TenantsByTenantIDGatewayQueryAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayPostApiV1TenantsByTenantIDGatewayQuery(pathParams, query, body) — suspend |
| python | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_gateway_query(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_gateway_query(path_params: …, query: …, body: …) |
| generic | request("gatewayPostApiV1TenantsByTenantIDGatewayQuery", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
Request body — pass via body, wire keys (snake_case) as-is
| Name | Type | Description |
|---|---|---|
action | string | |
params | array<any> | |
session_id | string | |
sql | string |
Response — 200 · OK
| Name | Type | Description |
|---|---|---|
columns | array<object> | |
rows | array<array> |
Error statuses: 400 401 403 404 500 — Error handling
POST /api/v1/tenants/{tenantID}/gateway/sessions
gatewayPostApiV1TenantsByTenantIDGatewaySessions
사용자가 connector 에 대한 active grant 의 preset 을 snapshot 으로 8시간 TTL session 시작.
- 호출 권한: tenant_member
- 입력: connector_id · mfa_verified?
- 부수 효과: gateway_sessions INSERT
| Language | Call |
|---|---|
| node | sdk.tenant(tenantId).gateway.sessions.create(…) — 인자·반환 타입은 패키지의 TypeScript 정의 참조 |
| go | client.Gateway().GatewayPostApiV1TenantsByTenantIDGatewaySessions(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayPostApiV1TenantsByTenantIDGatewaySessions(pathParams, query, body) — async: gatewayPostApiV1TenantsByTenantIDGatewaySessionsAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayPostApiV1TenantsByTenantIDGatewaySessions(pathParams, query, body) — suspend |
| python | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_gateway_sessions(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_post_api_v1_tenants_by_tenant_id_gateway_sessions(path_params: …, query: …, body: …) |
| generic | request("gatewayPostApiV1TenantsByTenantIDGatewaySessions", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
Request body — pass via body, wire keys (snake_case) as-is
| Name | Type | Description |
|---|---|---|
connector_id | string | |
mfa_verified | boolean |
Response — 201 · Created
| Name | Type | Description |
|---|---|---|
connectorId (wire: connector_id) | string | |
endedAt (wire: ended_at) | string | |
expiresAt (wire: expires_at) | string | |
grantId (wire: grant_id) | string | |
id | string | |
presetId (wire: preset_id) | string | |
startedAt (wire: started_at) | string | |
subjectId (wire: subject_id) | string | |
tenantId (wire: tenant_id) | string |
Error statuses: 400 401 403 404 500 — Error handling
DELETE /api/v1/tenants/{tenantID}/gateway/sessions/{sessionID}
gatewayDeleteApiV1TenantsByTenantIDGatewaySessionsBySessionID
- 호출 권한: tenant_member (자기 세션만)
| Language | Call |
|---|---|
| node | sdk.tenant(tenantId).gateway.sessions.end(…) — 인자·반환 타입은 패키지의 TypeScript 정의 참조 |
| go | client.Gateway().GatewayDeleteApiV1TenantsByTenantIDGatewaySessionsBySessionID(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayDeleteApiV1TenantsByTenantIDGatewaySessionsBySessionID(pathParams, query, body) — async: gatewayDeleteApiV1TenantsByTenantIDGatewaySessionsBySessionIDAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayDeleteApiV1TenantsByTenantIDGatewaySessionsBySessionID(pathParams, query, body) — suspend |
| python | client.gateway.gateway_delete_api_v1_tenants_by_tenant_id_gateway_sessions_by_session_id(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_delete_api_v1_tenants_by_tenant_id_gateway_sessions_by_session_id(path_params: …, query: …, body: …) |
| generic | request("gatewayDeleteApiV1TenantsByTenantIDGatewaySessionsBySessionID", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
sessionID required | string | session UUID |
Response — 204 · No Content
No body → the SDK returns an empty map {}
Error statuses: 400 401 403 404 500 — Error handling
GET /api/v1/tenants/{tenantID}/me/connectors
gatewayGetApiV1TenantsByTenantIDMeConnectors
현재 사용자가 active grant 를 가진 connector 들을 반환. 없는 connector 는 노출 0 (FR-018).
- 호출 권한: tenant_member
| Language | Call |
|---|---|
| node | sdk.tenant(tenantId).gateway.me.… — connectors()/connectorResources() (TypeScript 정의 참조) |
| go | client.Gateway().GatewayGetApiV1TenantsByTenantIDMeConnectors(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayGetApiV1TenantsByTenantIDMeConnectors(pathParams, query, body) — async: gatewayGetApiV1TenantsByTenantIDMeConnectorsAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayGetApiV1TenantsByTenantIDMeConnectors(pathParams, query, body) — suspend |
| python | client.gateway.gateway_get_api_v1_tenants_by_tenant_id_me_connectors(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_get_api_v1_tenants_by_tenant_id_me_connectors(path_params: …, query: …, body: …) |
| generic | request("gatewayGetApiV1TenantsByTenantIDMeConnectors", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
Response — 200 · OK
Array response → the SDK wraps it as {"value": [...]}. Element fields:
| Name | Type | Description |
|---|---|---|
classification | array<string> | Classification 은 자유 태그. |
config | object | Config 는 engine 별 설정 (credential 제외). |
createdAt (wire: created_at) | string | |
description | string | Description 은 admin 메모. |
enabled | boolean | |
engine | string | Engine 은 postgres / mysql / mssql / oracle / clickhouse / vertica / rest-api + mysql wire-compatible alias (mariadb / tidb / singlestore) + postgres wire-compatible alias (cockroachdb / yugabytedb / redshift / greenplum / spanner) + oracle alias (tibero). alias 는 UI / catalog 식별만 별, driver / discovery 동일. Aurora / Azure 같은 cloud-managed wrapper 는 host 만 다른 같은 product 라 별도 카드 없이 mysql / postgres / mssql 사용. |
id | string | ID 는 connector UUID. |
kind | string | Kind 는 db / api. |
lastDiscoveredAt (wire: last_discovered_at) | string | LastDiscoveredAt 는 마지막 발견 시각. |
name | string | Name 은 unique connector 이름. |
tenantId (wire: tenant_id) | string | TenantID 는 소속 tenant UUID. |
updatedAt (wire: updated_at) | string |
Error statuses: 401 403 500 — Error handling
GET /api/v1/tenants/{tenantID}/me/connectors/{connectorID}/resources
gatewayGetApiV1TenantsByTenantIDMeConnectorsByConnectorIDResources
active grant 없는 connector 는 404 — 메타데이터 자체 노출 0 (FR-018).
- 호출 권한: tenant_member
| Language | Call |
|---|---|
| node | sdk.tenant(tenantId).gateway.me.… — connectors()/connectorResources() (TypeScript 정의 참조) |
| go | client.Gateway().GatewayGetApiV1TenantsByTenantIDMeConnectorsByConnectorIDResources(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayGetApiV1TenantsByTenantIDMeConnectorsByConnectorIDResources(pathParams, query, body) — async: gatewayGetApiV1TenantsByTenantIDMeConnectorsByConnectorIDResourcesAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayGetApiV1TenantsByTenantIDMeConnectorsByConnectorIDResources(pathParams, query, body) — suspend |
| python | client.gateway.gateway_get_api_v1_tenants_by_tenant_id_me_connectors_by_connector_id_resources(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_get_api_v1_tenants_by_tenant_id_me_connectors_by_connector_id_resources(path_params: …, query: …, body: …) |
| generic | request("gatewayGetApiV1TenantsByTenantIDMeConnectorsByConnectorIDResources", pathParams, query, body) |
Path parameters — pass via pathParams
| Name | Type | Description |
|---|---|---|
tenantID required | string | 테넌트 UUID |
connectorID required | string | connector UUID |
Query parameters — pass via query (string values)
| Name | Type | Description |
|---|---|---|
limit | integer | 페이지 크기 (기본 100, 1~500 clamp) |
offset | integer | 오프셋 (기본 0) |
q | string | name 부분일치 필터 (대소문자 무시) |
parent_id | string | 부모 리소스 UUID — 주면 그 직계 자식(컬럼) 전체를 페이징 없이 반환 (limit/offset/q 무시) |
roots_only | boolean | true 면 최상위(테이블/엔드포인트)만 페이징 — 한 테이블의 컬럼이 페이지 경계에 잘리지 않아요 |
Response — 200 · OK
Paginated response { items: [...], total, next_cursor } — next_cursor is omitted on the last page. items element fields:
| Name | Type | Description |
|---|---|---|
attributes | object | |
classification | array<string> | |
connectorId (wire: connector_id) | string | |
createdAt (wire: created_at) | string | |
id | string | |
kind | string | |
name | string | |
parentId (wire: parent_id) | string | |
path | string | |
tenantId (wire: tenant_id) | string | |
updatedAt (wire: updated_at) | string |
Error statuses: 401 403 404 500 — Error handling
GET /config/public
configGetConfigPublic
로그인 / 로그아웃 / 만료 토큰 상태와 무관하게 호출 가능한 익명 endpoint.
FE 가 부트스트랩 시 1회 호출 후 메모리 캐시. 현재 base_domain 만 반환.
| Language | Call |
|---|---|
| node | sdk.config.public(…) — resource model — see the package's TypeScript definitions for arguments and return types |
| go | client.Gateway().ConfigGetConfigPublic(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().configGetConfigPublic(pathParams, query, body) — async: configGetConfigPublicAsync(…) → CompletableFuture |
| kotlin | client.gateway.configGetConfigPublic(pathParams, query, body) — suspend |
| python | client.gateway.config_get_config_public(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.config_get_config_public(path_params: …, query: …, body: …) |
| generic | request("configGetConfigPublic", pathParams, query, body) |
Response — 200 · OK
| Name | Type | Description |
|---|---|---|
baseDomain (wire: base_domain) | string |
Error statuses: 429 — Error handling
GET /api/v1/oauth/google/callback
gatewayGetOauthGoogleCallback · 302 → {status, location}
Google 동의 후 redirect 받는 endpoint. code + code_verifier 로 token 교환, Shared Drive 목록을 oauth_state row 에 저장. Accept 헤더 분기:
- text/html (브라우저): 302 redirect to return_to?state=... (FE 가 이어받음)
- application/json: 기존 JSON 응답 (자동화 / curl 용)
- 호출 권한: 인증된 사용자 (state 가 secret 역할 — 10분 TTL).
- 입력: code · state (query string)
- 부수 효과: oauth_states row 갱신 (callback_payload 채움)
| Language | Call |
|---|---|
| node | not provided |
| go | client.Gateway().GatewayGetOauthGoogleCallback(ctx, axhub.OperationParams{PathParams: …, Query: …, Body: …}) |
| java | client.gateway().gatewayGetOauthGoogleCallback(pathParams, query, body) — async: gatewayGetOauthGoogleCallbackAsync(…) → CompletableFuture |
| kotlin | client.gateway.gatewayGetOauthGoogleCallback(pathParams, query, body) — suspend |
| python | client.gateway.gateway_get_oauth_google_callback(path_params=…, query=…, body=…) — AsyncAxHubClient awaits the same name |
| ruby | client.gateway.gateway_get_oauth_google_callback(path_params: …, query: …, body: …) |
| generic | request("gatewayGetOauthGoogleCallback", pathParams, query, body) |
Query parameters — pass via query (string values)
| Name | Type | Description |
|---|---|---|
code required | string | Google authorization code |
state required | string | start 단계에서 발급된 state |
error | string | Google 에서 사용자 거부 시 access_denied |
Response — 200 · Shared Drive 목록 (Accept: application/json)
| Name | Type | Description |
|---|---|---|
drives | array<object> | |
returnTo (wire: return_to) | string | |
state | string | |
tenantId (wire: tenant_id) | string |
On 302 the SDK returns {"status": 302, "location": "..."} (redirects are not followed)
Error statuses: 400 401 500 — Error handling