Skip to main content

Shares

SDK methods for the Shares module, accessed via soat.shares. See the Shares module docs for permissions and data model, and each method's REST page for the full request/response schema.

soat.shares.createShare()​

Create a share

  • Method: POST
  • Path: /api/v1/shares
await soat.shares.createShare({
body: { resource, actions, grantee, /* + optional */ },
});

→ Request & response schema

soat.shares.listShares()​

List shares

  • Method: GET
  • Path: /api/v1/shares
await soat.shares.listShares({
query: { /* + optional */ },
});

→ Request & response schema

soat.shares.getShare()​

Get a share

  • Method: GET
  • Path: /api/v1/shares/{share_id}
await soat.shares.getShare({
path: { share_id },
query: { /* + optional */ },
});

→ Request & response schema

soat.shares.updateShare()​

Update a share

  • Method: PATCH
  • Path: /api/v1/shares/{share_id}
await soat.shares.updateShare({
path: { share_id },
body: { /* + optional */ },
});

→ Request & response schema

soat.shares.deleteShare()​

Delete a share

  • Method: DELETE
  • Path: /api/v1/shares/{share_id}
await soat.shares.deleteShare({
path: { share_id },
});

→ Request & response schema

soat.shares.acceptShare()​

Accept a share

  • Method: POST
  • Path: /api/v1/shares/{share_id}/accept
await soat.shares.acceptShare({
path: { share_id },
body: { /* + optional */ },
});

→ Request & response schema

soat.shares.suspendShare()​

Suspend a share

  • Method: POST
  • Path: /api/v1/shares/{share_id}/suspend
await soat.shares.suspendShare({
path: { share_id },
});

→ Request & response schema

soat.shares.resumeShare()​

Resume a share

  • Method: POST
  • Path: /api/v1/shares/{share_id}/resume
await soat.shares.resumeShare({
path: { share_id },
});

→ Request & response schema

soat.shares.revokeShare()​

Revoke a share

  • Method: POST
  • Path: /api/v1/shares/{share_id}/revoke
await soat.shares.revokeShare({
path: { share_id },
query: { /* + optional */ },
body: { /* + optional */ },
});

→ Request & response schema

soat.shares.listShareReferences()​

List a grantee's references to a shared resource

  • Method: GET
  • Path: /api/v1/shares/{share_id}/references
await soat.shares.listShareReferences({
path: { share_id },
query: { /* + optional */ },
});

→ Request & response schema

soat.shares.listShareAcceptances()​

List a share's acceptances

  • Method: GET
  • Path: /api/v1/shares/{share_id}/acceptances
await soat.shares.listShareAcceptances({
path: { share_id },
query: { /* + optional */ },
});

→ Request & response schema

soat.shares.revokeShareAcceptance()​

Revoke an acceptance

  • Method: POST
  • Path: /api/v1/shares/{share_id}/acceptances/{acceptance_id}/revoke
await soat.shares.revokeShareAcceptance({
path: { share_id, acceptance_id },
});

→ Request & response schema

soat.shares.deleteShareAcceptance()​

Delete an acceptance

  • Method: DELETE
  • Path: /api/v1/shares/{share_id}/acceptances/{acceptance_id}
await soat.shares.deleteShareAcceptance({
path: { share_id, acceptance_id },
});

→ Request & response schema