Griffin Memberships API
Memberships represents the relationship between a [user](#tag/Users) and an [organization](#tag/Organizations). A membership must have at least one [role](#tag/Roles) assigned to it.
Memberships represents the relationship between a [user](#tag/Users) and an [organization](#tag/Organizations). A membership must have at least one [role](#tag/Roles) assigned to it.
swagger: '2.0'
info:
title: The Griffin API keys Memberships API
version: ''
description: "## Introduction\n\nThe Griffin API is based on [REST](https://en.wikipedia.org/wiki/Representational_state_transfer).\nIt has resource-oriented URLs, accepts [JSON](https://www.json.org/json-en.html)-encoded request bodies, returns [JSON](https://www.json.org/json-en.html)-encoded responses, and uses standard HTTP response verbs and response codes.\n\nOur API deviates from strict RESTful principles if it makes sense to do so, such as when we enforce tighter access controls around certain operations.\nFor example, when closing a bank account: rather than send a PATCH request to the [bank account](#tag/Bank-accounts) resource to update it's status to `\"closed\"`, we provide a dedicated account closure resource.\n\nAnyone can [create an account](https://app.griffin.com/register) with Griffin and try out our API in [sandbox mode](/docs/guides/sandbox-vs-live-mode).\n\nNew to Griffin? Check out our [getting started guide](/docs/guides/get-started-with-the-api).\n\n## Navigation\n\nOur API is designed to be navigated programmatically. When you request any resource, you will find the URLs for related resources in the response body.\n\nThe API is structured as a tree with your [organization](#tag/Organizations) at the top. Everything that you own will be a sub-resource of your organization.\n\nTo bootstrap the navigation process, request the [index](#tag/Navigation/paths/~1v0~1index/get) endpoint: the response will contain your `organization-url`.\n\nFor a walkthrough, see our [getting started guide](/docs/guides/get-started-with-the-api).\n\n## Pagination\n\nOur list APIs support pagination (e.g. [list bank accounts](#tag/Bank-accounts/paths/~1v0~1organizations~1%7Borganization-id%7D~1bank~1accounts/get) and [list payments](#tag/Payments/paths/~1v0~1bank~1accounts~1%7Bbank-account-id%7D~1payments/get)).\nBy default, a list API returns up to 25 results. If there are more results available, the response payload will include links to the previous/next pages.\n\n### Change page size\n\nYou can request a different number of results (between 1 and 200, inclusive) by using the `page[size]` query parameter:\n\n```\nGET /v0/organizations/:id/bank/accounts?page[size]=100\n```\n\n### Navigating between pages\n\nList responses will include a `links` object with `prev` and `next` attributes, as shown below.\nPerform a GET request to the value of the attribute to fetch the previous/next page of results.\n\n```\n{\n \"accounts\": [\n // ...\n ],\n \"links\": {\n \"prev\": \"/v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/bank/accounts?page[before]=djE6WxSPxfYUTnCU9XtWzj9gGA\",\n \"next\": \"/v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/bank/accounts?page[after]=djE6aw79PXZySUOL16LD8HRJ3A\"\n }\n}\n\n```\nIf there is no previous or next page available, the value of the attribute will be null.\n\nAny other query parameters included in the initial request will also be included in the response payload's links.\nIf you want to change parameters (see [filtering and sorting](#section/Filtering-and-sorting)), request the first page and follow the links from there.\n\n## Filtering and sorting\n\n### Sort results\n\nBy default, resources will be listed in descending order, usually based on the `created-at` attribute.\nYou can change the sorting behaviour of a list of results by using the `sort` query parameter.\n\nFor example, to list bank accounts in ascending order (oldest first):\n\n```\nGET /v0/organizations/:id/bank/accounts?sort=created-at\n```\n\nTo _explicitly_ sort in descending order (newest first), prefix the sort attribute with `-`:\n\n```\nGET /v0/organizations/:id/bank/accounts?sort=-created-at\n```\n\n### Filter results\n\nSome list APIs allow you to filter the results.\nFilters are expressed as nested data structures encoded into query parameters.\nFor example, you can list bank accounts that are in either the `opening` or `open` state with:\n\n```\nGET /v0/organizations/:id/bank/accounts?filter[account-status][in][]=opening&filter[account-status][in][]=open\n```\n\nSimilarly, you can list legal persons with a specific `application-status`:\n\n```\nGET /v0/organizations/:id/legal-persons?filter[application-status][eq]=accepted\n```\n\n### Include resources\n\nSome list APIs allow you to include associated resources in the response, reducing the number of requests needed to fetch related data.\nFor instance, when listing bank accounts, you can include each bank account's beneficiary legal person by using the `include` query parameter:\n\n```\nGET /v0/organizations/:id/bank/accounts?include=beneficiary\n```\n\nThe response returns the usual list of bank accounts, but it will also have an `included` object with a `legal-persons` attribute:\n\n```\n{\n \"accounts\": [\n // ...\n ],\n \"links\": {\n // ...\n }\n \"included\": {\n \"legal-persons\": [\n // ...\n ]\n }\n}\n```\n\nCheck the documentation for each list API to see all options for sorting and filtering\n\n## Request limits\n\nEach organization is allowed up to 50 concurrent (in-flight) API requests. Exceeding this threshold results in a 429 - Too Many Requests response. Upon receiving a 429 response, you should implement a backoff strategy, pausing to allow your outstanding requests to complete before attempting new requests. To manage your request rate effectively and avoid surpassing this limit, consider using a controlled approach such as a finite pool of threads or workers.\n\n## Versioning\n\nThe Griffin API is versioned via a prefix in the URL.\nThe current version is v0.\nAn example endpoint is: https://api.griffin.com/v0/index.\n\nWe will not break your integration with a particular version for as long as we support that version.\nIf we release a new version, you will have 12 months to upgrade to it."
host: api.griffin.com
basePath: /
schemes:
- https
consumes:
- application/json
produces:
- application/json
security:
- api-key-auth: []
tags:
- name: Memberships
description: "Memberships represents the relationship between a [user](#tag/Users) and an [organization](#tag/Organizations).\n A membership must have at least one [role](#tag/Roles) assigned to it."
paths:
/v0/memberships/{membership-id}:
get:
tags:
- Memberships
description: Returns the [user's](#tag/Users) [membership](#tag/Memberships) information.
parameters:
- type: string
required: true
name: membership-id
in: path
responses:
'200':
schema:
type: object
properties:
membership-url:
type: string
x-allOf:
- type: string
- {}
- type: object
properties:
membership-id:
type: string
format: ''
title: membership-id
required: true
name: membership-id
required:
- membership-id
x-anyOf:
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
membership-id:
type: string
format: ''
title: membership-id
required: true
name: membership-id
required:
- membership-id
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
membership-id:
type: string
format: ''
title: membership-id
required: true
name: membership-id
required:
- membership-id
title: membership-url
example: /v0/memberships/mp.ICAgbWVtYmVyc2hpcC1pZA
description: Link to the [membership](#tag/Memberships).
membership-roles-url:
type: string
x-allOf:
- type: string
- {}
- type: object
properties:
membership-id:
type: string
format: ''
title: membership-id
required: true
name: membership-id
required:
- membership-id
x-anyOf:
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
membership-id:
type: string
format: ''
title: membership-id
required: true
name: membership-id
required:
- membership-id
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
membership-id:
type: string
format: ''
title: membership-id
required: true
name: membership-id
required:
- membership-id
title: membership-roles-url
example: /v0/memberships/mp.ICAgbWVtYmVyc2hpcC1pZA/roles
description: Link to the assigned [roles](#tag/Roles) for this [membership](#tag/Memberships).
organization:
type: object
properties:
own-legal-person-url:
type: string
x-allOf:
- type: string
- {}
- type: object
properties:
legal-person-id:
type: string
format: ''
title: legal-person-id
required: true
name: legal-person-id
required:
- legal-person-id
x-anyOf:
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
legal-person-id:
type: string
format: ''
title: legal-person-id
required: true
name: legal-person-id
required:
- legal-person-id
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
legal-person-id:
type: string
format: ''
title: legal-person-id
required: true
name: legal-person-id
required:
- legal-person-id
title: own-legal-person-url
example: /v0/legal-persons/lp.IGxlZ2FsLXBlcnNvbi1pZA
description: Link to the [legal person](#tag/Legal-persons) that represents the [organization](#tag/Organizations); this can be an individual or a company.
organization-mode:
title: organization-mode
enum:
- test-mode
- live-mode
type: string
description: The organization can either be a sandbox organization or a live one; Check out our guide for [sandbox mode vs live mode](/docs/guides/sandbox-vs-live-mode).
organization-memberships-url:
type: string
title: organization-memberships-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/memberships
description: Link to the [memberships](#tag/Memberships) for this [organization](#tag/Organizations).
organization-invitations-url:
type: string
title: organization-invitations-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/invitations
description: Link to the resource that enables you to [invite](#tag/Invites) new [users](#tag/Users) to this [organization](#tag/Organizations).
organization-payments-url:
type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
x-anyOf:
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
title: organization-payments-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/payments
description: Link to the [payments](#tag/Payments) associated with this organization.
organization-bank-account-products-url:
type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
x-anyOf:
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
title: organization-bank-account-products-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/bank/products
description: Link to the [bank account](#tag/Bank-accounts) products owned by this [organization](#tag/Organization).
organization-onboarding-applications-url:
type: string
title: organization-onboarding-applications-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/onboarding/applications
description: Link to the [Reliance onboarding](#tag/Reliance-onboarding).
display-name:
type: string
minLength: 1
title: display-name
description: A human readable label for an entity
organization-bank-accounts-search-url:
type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
x-anyOf:
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
title: organization-bank-accounts-search-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/bank/accounts/search
description: Link to search [bank accounts](#tag/Bank-accounts) associated with this [organization](#tag/Organizations).
organization-api-keys-url:
type: string
title: organization-api-keys-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/api-keys
organization-live-access-url:
type: string
title: organization-live-access-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/live-access
description: Link to the resource that enables you to request live access.
organization-webhooks-url:
type: string
title: organization-webhooks-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/webhooks
description: Link to the endpoint which enables webhook creation.
organization-workflows-url:
type: string
title: organization-workflows-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/workflows
description: Link to the onboarding [workflows](#tag/Workflows) configured for this [organization](#tag/Organizations).
organization-bank-accounts-url:
type: string
title: organization-bank-accounts-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/bank/accounts
description: Link to the [bank accounts](#tag/Bank-accounts) managed by this [organization](#tag/Organizations).
available-roles:
type: array
items:
type: object
properties:
display-name:
type: string
minLength: 1
title: display-name
description: A human readable label for an entity
description:
type: string
title: description
role-url:
type: string
x-allOf:
- type: string
- {}
- type: object
properties:
role-id:
type: string
format: ''
title: role-id
required: true
name: role-id
required:
- role-id
x-anyOf:
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
role-id:
type: string
format: ''
title: role-id
required: true
name: role-id
required:
- role-id
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
role-id:
type: string
format: ''
title: role-id
required: true
name: role-id
required:
- role-id
title: role-url
example: /v0/roles/re.ICAgICAgICAgcm9sZS1pZA
description: Link to the [role](#tag/Roles).
role-category:
type: string
required:
- display-name
- description
- role-url
title: role
description: The subset of [roles](#tag/Roles) available to [members](#tag/Members) of this [organization](#tag/Organizations).
title: available-roles
can-decide-on-verifications?:
type: boolean
title: can-decide-on-verifications?
description: Is this organization able to make manual decisions on verifications?
organization-url:
type: string
title: organization-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA
description: Link to the [organization](#tag/Organizations).
organization-payments-search-url:
type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
x-anyOf:
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
organization-id:
type: string
format: ''
title: organization-id
required: true
name: organization-id
required:
- organization-id
title: organization-payments-search-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/payments/search
description: Link to search [payments](#tag/Payments) associated with this organization.
organization-individuals-url:
type: string
title: organization-individuals-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/individuals
organization-corporations-url:
type: string
title: organization-corporations-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/corporations
organization-legal-persons-url:
type: string
title: organization-legal-persons-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/legal-persons
description: Link to the [legal persons](#tag/Legal-persons) grouped under this [organization](#tag/Organizations).
organization-legal-persons-search-url:
type: string
title: organization-legal-persons-search-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/legal-persons/search
description: Link to search [legal persons](#tag/Legal-persons) grouped under this [organization](#tag/Organizations).
organization-events-url:
type: string
title: organization-events-url
example: /v0/organizations/og.IG9yZ2FuaXphdGlvbi1pZA/events
description: Link to the endpoint which lists an organization's events.
required:
- available-roles
- can-decide-on-verifications?
- display-name
- organization-api-keys-url
- organization-bank-accounts-url
- organization-bank-account-products-url
- organization-corporations-url
- organization-events-url
- organization-individuals-url
- organization-invitations-url
- organization-legal-persons-url
- organization-live-access-url
- organization-memberships-url
- organization-mode
- organization-payments-url
- organization-url
- organization-webhooks-url
- organization-workflows-url
- own-legal-person-url
- organization-legal-persons-search-url
- organization-bank-accounts-search-url
- organization-payments-search-url
title: organization
description: Shows the associated [organization](#tag/Organizations).
roles:
type: array
items:
type: object
properties:
display-name:
type: string
minLength: 1
title: display-name
description: A human readable label for an entity
description:
type: string
title: description
role-url:
type: string
x-allOf:
- type: string
- {}
- type: object
properties:
role-id:
type: string
format: ''
title: role-id
required: true
name: role-id
required:
- role-id
x-anyOf:
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
role-id:
type: string
format: ''
title: role-id
required: true
name: role-id
required:
- role-id
- type: string
x-allOf:
- type: string
- {}
- type: object
properties:
role-id:
type: string
format: ''
title: role-id
required: true
name: role-id
required:
- role-id
title: role-url
example: /v0/roles/re.ICAgICAgICAgcm9sZS1pZA
description: Link to the [role](#tag/Roles).
role-category:
type: string
required:
- display-name
- description
- role-url
title: role
title: roles
description: Shows a collection of [roles](#tag/Roles).
user:
type: object
properties:
user-email:
type: string
title: user-email
example: user@example.com
description: The user's email address.
user-url:
type: string
title: user-url
example: /v0/users/ur.ICAgICAgICAgdXNlci1pZA
description: Link to the user.
user-username:
type: string
title: user-username
example: user@example.com
description: The username.
api-keys-url:
type: string
x-allOf:
- type: string
# --- truncated at 32 KB (110 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/griffin/refs/heads/main/openapi/griffin-memberships-api-openapi.yml