Return a list of relationships based on either the customer or partner, or all relationships.

Permission Level: Read

GET /tenants/relationships

Operation id: CustomerPartnerRelationshipService_ListRelationships

Tags: CustomerPartnerRelationshipService

Parameters

Query parameters

NameTypeRequiredDescription
customerTenantIdstringNoOptional - if you want to list all relationships for a particular customer.
pageSizeinteger (int32)NoPage Size, Default: 10, Required: false
pageTokenstringNoMongoDB Field, describes the encoded page token for page traversal, Required: false
partnerTenantIdstringNoOptional - if you want to list all relationships for a particular partner.
sortFieldstringNoSort field, valid values: relationshipId, customerTenantId or partnerTenantId, Default: relationshipId, Required: false
sortTypestringNoSort Type for the results, Default: ASC, Required: false

Security

  • Authorization (apiKey)
    • Bearer token

Responses

200 — A successful response.

Content type: application/json

default — An unexpected error response.

Content type: application/json

Response models

200 — A successful response.

Content type: application/json

Schema

PropertyTypeRequiredDescription
relationshiparrayNo
nextPageTokenstringNoThe token of the next page of results.
{
  "type": "object",
  "properties": {
    "relationship": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "relationshipId": {
            "type": "string",
            "description": "A server-side generated unique Id. It cannot be provided."
          },
          "customerTenantId": {
            "type": "string",
            "description": "The platform tenantId of the customer in the relationship. Required: true."
          },
          "partnerTenantId": {
            "type": "string",
            "description": "The platform tenantId of the partner in the relationship.  Required: true."
          },
          "concatCustPartId": {
            "type": "string",
            "description": "A concatenated Id of the customerTenantId_partnerTenantId.  Unique because there can only be one relationship per customer/partner combination."
          },
          "attributes": {
            "type": "array",
            "description": "The attributes associated with the relationship.",
            "items": {
              "type": "object"
            }
          }
        }
      }
    },
    "nextPageToken": {
      "type": "string",
      "description": "The token of the next page of results."
    }
  }
}

default — An unexpected error response.

Content type: application/json

Schema

PropertyTypeRequiredDescription
codeinteger (int32)No
messagestringNo
detailsarrayNo
{
  "type": "object",
  "properties": {
    "code": {
      "type": "integer",
      "format": "int32"
    },
    "message": {
      "type": "string"
    },
    "details": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "@type": {
            "type": "string"
          }
        }
      }
    }
  }
}