PUT/api/apis/{api_server_id}/organization-membership-visibilityAdmin

Set an API server's organization membership visibility

Sets which organizations' memberships the API server may look up on the resource-server endpoints (GET /api/resource-server/organizations/{organization_id}/members/{uid}/role and GET /api/resource-server/users/{uid}/organizations). By default an API server only sees its owning organization; all_organizations is meant for multi-tenant platform services that serve every organization, and lookups outside the owning organization must carry the user's access token for the API server in X-Subject-Token. Platform administrators only: the API server's own managers cannot widen it. Hardcoded API servers cannot be changed.

operationId put_api_apis_api_server_id_organization_membership_visibilityAPI servers

Authentication & permissionsAdmin

Platform administrators only

Accepted credentials
Who may call
Platform administrators only

Path parameters

NameTypeDescription
api_server_id*string

API server id

Request body

Required

application/json
ApiServerOrganizationMembershipVisibilityUpdate
PropertyTypeDescription
organization_membership_visibility*"owning_organization" | "all_organizations"

owning_organization: the API server may look up memberships of its own organization only (the default). all_organizations: it may look up a user's memberships in any organization, but only while presenting that user's access token for the API server.

JSONExample
"organization_membership_visibility""all_organizations"

Responses

application/json
ApiServerResponse
PropertyTypeDescription
success*true
api_server*ApiServerDefinition

An API server (resource server) registration: identity, listing visibility, ownership (platform / organization / user), dynamic-client policy, organization membership visibility and delegated-token policy.

api_server_id*string

minLength: 2maxLength: 64pattern: ^[a-z0-9_-]*$

api_server_name*string

maxLength: 64

api_server_description*string

maxLength: 512

created_at*number

minimum: 0

public*boolean
hardcoded*boolean
owner_type"platform" | "organization" | "user" | "dynamic-client-registration"
owner_organization_idstring | null | null
owner_uidstring (uuid) | null (uuid) | null
created_bystring (uuid) | null (uuid) | null
allow_dynamic_clientsboolean
resource_url_match_mode"exact" | "prefix"
organization_membership_visibility"owning_organization" | "all_organizations"
accept_delegated_tokensboolean
JSONExample
"success"true
"api_server"
"api_server_id""string"
"api_server_name""string"
"api_server_description""string"
"created_at"1.5
"public"true
"hardcoded"true
"owner_type""platform"
"owner_organization_id""string"
"owner_uid""123e4567-e89b-12d3-a456-426614174000"
"created_by""123e4567-e89b-12d3-a456-426614174000"
"allow_dynamic_clients"true
"resource_url_match_mode""exact"
"organization_membership_visibility""owning_organization"
"accept_delegated_tokens"true

Example request

bashcurl
curl -X PUT 'https://auth.schemavaults.com/api/apis/<api_server_id>/organization-membership-visibility' \
  -b 'refresh_token_<auth_server_app_id>=<value>' \
  -H 'Content-Type: application/json' \
  -d '{
  "organization_membership_visibility": "all_organizations"
}'