API · v1 · estable
CODEMETA OSDeveloper Center
ES
Abrir la consola
Entidad · tenant_links

Tenant Link Schema

ID del esquema
tenant_link
Colección
tenant_links
Permisos
  • Leertenant_link_view
  • Creartenant_link_manage
  • Modificartenant_link_manage
  • Eliminartenant_link_manage

Campos

Tenant Link Schema

tenant_links4 permisos

Consent-based federation link between two Codemeta tenants, possibly on different installations (ADR 0445)

labelstringopcional

Display name for the connection list. Never sent over the wire.

máx. 120 caracteresadmite null
peerKindstringobligatorio

local = another tenant of this installation (loopback, no secrets); remote = a foreign installation (signed HTTPS).

localremote
solo lectura
baseUrlstringopcional

Remote only. HTTPS enforced and re-validated against assertSafeOutgoingUrl before every call (SSRF).

máx. 500 caracteresadmite null
peerInstallationIdstringopcional

Opaque id of the counterpart installation, stamped during the handshake.

máx. 200 caracteressolo lecturaadmite null
peerTenantIdstringopcional

Counterpart tenant. Stamped on redemption only — never client-writable.

solo lecturaadmite null
invitationCodestringopcional

Server-generated invitation. Unique while pending, cleared on redemption. Redacted from every read.

solo lecturaadmite null
invitationExpiresAtdatetimeopcional

After this instant the code no longer redeems.

solo lecturaadmite null
statusstringobligatorio
pendingacceptedrevoked
Valor por defecto: "pending"solo lectura
revokedSidestringopcional

Which side ended it. Both sides may revoke.

initiatorpeer
solo lecturaadmite null
rolesobjectopcional
admite null
mspTenantIdstringopcional
admite null
customerTenantIdstringopcional
admite null
partyIduuidopcional

THE anchor — the customer party in the MSP CRM. Never leaves the installation.

admite null
protocolVersionintegeropcional

Negotiated major version, min(local, peer).

≥ 1Valor por defecto: 1solo lectura
capabilitiesobjectopcional

What the PEER may do here. Server-enforced.

solo lectura
createTicketbooleanopcional
Valor por defecto: false
commentbooleanopcional
Valor por defecto: true
changeStatusbooleanopcional
Valor por defecto: true
changePrioritybooleanopcional
Valor por defecto: true
requestReturnbooleanopcional
Valor por defecto: true
peerCapabilitiesobjectopcional

What we may do there. Display / pre-flight only — never an authorisation basis.

solo lecturaadmite null
createTicketbooleanopcional
commentbooleanopcional
changeStatusbooleanopcional
changePrioritybooleanopcional
requestReturnbooleanopcional
inboundKeyIdstringopcional

NON-SECRET selector (X-Codemeta-Peer-Key). Installation-wide unique — the ingress knows no tenant yet.

solo lecturaadmite null
inboundSecretEncobjectopcional

AES-256-GCM blob of the secret inbound signatures are verified with. Encrypted, NOT hashed — HMAC verification needs the plaintext.

solo lecturaadmite null
__encryptedbooleanopcional
vintegeropcional
ivstringopcional
tagstringopcional
ciphertextstringopcional
inboundSecretRotatedAtdatetimeopcional
solo lecturaadmite null
outboundKeyIdstringopcional

The counterpart's selector — what we send in X-Codemeta-Peer-Key.

solo lecturaadmite null
outboundSecretEncobjectopcional

AES-256-GCM blob of the secret outbound signatures are created with.

solo lecturaadmite null
__encryptedbooleanopcional
vintegeropcional
ivstringopcional
tagstringopcional
ciphertextstringopcional
outboundSecretRotatedAtdatetimeopcional
solo lecturaadmite null
exchangeobjectopcional

TicketExchangeConfig (ADR 0363 §1b) — target, statusMap, priorityMap. Same type as the Jira side.

admite null
sharesIdentitybooleanopcional

ADR 1116: the row OWNER sends reporter (name, e-mail, phone) and location with a handed-over ticket. Each side decides for its own outbound direction.

Valor por defecto: falsesolo lectura
peerSharesIdentitybooleanopcional

ADR 1116: the same switch for the ACCEPTING side of a local link (one row serves both tenants). Unused on remote links, where each side owns its own row.

Valor por defecto: falsesolo lectura
locationMapobject[]opcional

ADR 1116: the counterpart's location key → one of OUR addresses on `partyId`. Only meaningful on the side that owns `partyId`.

máx. 500 elementossolo lectura
peerLocationKeystringobligatorio
1–128 caracteres
partyAddressIdstringobligatorio
1–64 caracteres
seenPeerLocationsobject[]opcional

ADR 1116: locations the counterpart has reported, with the address they resolved to (null = unresolved). Technical — written by the inbound path, read by the mapping UI.

máx. 500 elementossolo lectura
keystringobligatorio
máx. 128 caracteres
namestringopcional
máx. 200 caracteresadmite null
streetstringopcional
máx. 200 caracteresadmite null
postalCodestringopcional
máx. 20 caracteresadmite null
citystringopcional
máx. 100 caracteresadmite null
countryCodestringopcional
máx. 8 caracteresadmite null
resolvedAddressIdstringopcional
máx. 64 caracteresadmite null
lastSeenAtdatetimeopcional
acceptedAtdatetimeopcional
solo lecturaadmite null
acceptedBystringopcional
solo lecturaadmite null
revokedAtdatetimeopcional
solo lecturaadmite null
revokedBystringopcional
solo lecturaadmite null

Endpoints estándar

Este recurso sigue el contrato CRUD genérico de la plataforma. Lea las convenciones sobre paginación, idempotencia, bloqueo optimista y auditoría. Los endpoints principales:

  • GET /api/v1/tenant_links — Lista, paginada y filtrable
  • GET /api/v1/tenant_links/<id> — Una entidad
  • POST /api/v1/tenant_links — Crear
  • PATCH /api/v1/tenant_links/<id> — Actualización parcial
  • DELETE /api/v1/tenant_links/<id> — Eliminación lógica
  • GET /api/v1/tenant_links/<id>/timeline — Auditoría y actividades

Búsqueda