{
  "opencollection": "1.0.0",
  "info": {
    "name": "Affinity API v2 auth companies API",
    "version": "1.0"
  },
  "request": {
    "auth": {
      "type": "bearer",
      "token": "{{bearerToken}}"
    }
  },
  "items": [
    {
      "info": {
        "name": "companies",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "Get all Companies",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.affinity.co/v2/companies",
            "params": [
              {
                "name": "cursor",
                "value": "ICAgICAgYmVmb3JlOjo6Nw",
                "type": "query",
                "description": "Cursor for the next or previous page"
              },
              {
                "name": "limit",
                "value": "100",
                "type": "query",
                "description": "Number of items to include in the page"
              },
              {
                "name": "ids",
                "value": "1,2",
                "type": "query",
                "description": "Company IDs"
              },
              {
                "name": "fieldIds",
                "value": "field-1,field-2",
                "type": "query",
                "description": "Field IDs for which to return field data"
              },
              {
                "name": "fieldTypes",
                "value": "enriched,global",
                "type": "query",
                "description": "Field Types for which to return field data"
              }
            ]
          },
          "docs": "Paginate through Companies in Affinity.\nReturns basic information and non-list-specific field data on each Company.\n\nTo retrieve field data, you must use either the `fieldIds` or the `fieldTypes` parameter\nto specify the Fields for which you want data returned.\nThese Field IDs and Types can be found using the GET `/v2/companies/fields` endpoint.\nWhen no `fieldIds` or `fieldTypes` are provided, Companies will be returned without any field data attached.\nTo supply multiple `fieldIds` or `fieldType"
        },
        {
          "info": {
            "name": "Get a single Company",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.affinity.co/v2/companies/:companyId",
            "params": [
              {
                "name": "companyId",
                "value": "",
                "type": "path",
                "description": "Company ID"
              },
              {
                "name": "fieldIds",
                "value": "field-1,field-2",
                "type": "query",
                "description": "Field IDs for which to return field data"
              },
              {
                "name": "fieldTypes",
                "value": "enriched,global",
                "type": "query",
                "description": "Field Types for which to return field data"
              }
            ]
          },
          "docs": "Returns basic information and non-list-specific field data on the requested Company.\n\nTo retrieve field data, you must use either the `fieldIds` or the `fieldTypes` parameter\nto specify the Fields for which you want data returned.\nThese Field IDs and Types can be found using the GET `/v2/companies/fields` endpoint.\nWhen no `fieldIds` or `fieldTypes` are provided, Companies will be returned without any field data attached.\nTo supply multiple `fieldIds` or `fieldTypes` parameters, generate a query"
        },
        {
          "info": {
            "name": "Get metadata on Company Fields",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.affinity.co/v2/companies/fields",
            "params": [
              {
                "name": "cursor",
                "value": "ICAgICAgYmVmb3JlOjo6Nw",
                "type": "query",
                "description": "Cursor for the next or previous page"
              },
              {
                "name": "limit",
                "value": "100",
                "type": "query",
                "description": "Number of items to include in the page"
              }
            ]
          },
          "docs": "Returns metadata on non-list-specific Company Fields.\n\nUse the returned Field IDs to request field data from the GET `/v2/companies` and GET `/v2/companies/{id}` endpoints."
        },
        {
          "info": {
            "name": "Get a Company's Lists",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.affinity.co/v2/companies/:companyId/lists",
            "params": [
              {
                "name": "companyId",
                "value": "",
                "type": "path",
                "description": "Company ID"
              },
              {
                "name": "cursor",
                "value": "ICAgICAgYmVmb3JlOjo6Nw",
                "type": "query",
                "description": "Cursor for the next or previous page"
              },
              {
                "name": "limit",
                "value": "100",
                "type": "query",
                "description": "Number of items to include in the page"
              }
            ]
          },
          "docs": "Paginate through all Lists where the given Company appears as an entry and that you have access to view.\nReturns basic List information for each List that contains this Company."
        },
        {
          "info": {
            "name": "Get a Company's List Entries",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.affinity.co/v2/companies/:companyId/list-entries",
            "params": [
              {
                "name": "companyId",
                "value": "",
                "type": "path",
                "description": "Company ID"
              },
              {
                "name": "cursor",
                "value": "ICAgICAgYmVmb3JlOjo6Nw",
                "type": "query",
                "description": "Cursor for the next or previous page"
              },
              {
                "name": "limit",
                "value": "100",
                "type": "query",
                "description": "Number of items to include in the page"
              }
            ]
          },
          "docs": "Paginate through the List Entries (AKA rows) for the given Company across all Lists.\nEach List Entry includes field data for the Company, including list-specific field data.\nEach List Entry also includes metadata about its creation, i.e., when it was added to the List and by whom.\n\nRequires the \"Export data from Lists\" [permission](#section/Getting-Started/Permissions)."
        },
        {
          "info": {
            "name": "Get Notes for a Company",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.affinity.co/v2/companies/:companyId/notes",
            "params": [
              {
                "name": "companyId",
                "value": "",
                "type": "path",
                "description": "Company's ID"
              },
              {
                "name": "filter",
                "value": "",
                "type": "query",
                "description": "Filter options"
              },
              {
                "name": "cursor",
                "value": "",
                "type": "query",
                "description": "Cursor for the next or previous page"
              },
              {
                "name": "limit",
                "value": "",
                "type": "query",
                "description": "Number of items to include in the page"
              },
              {
                "name": "totalCount",
                "value": "",
                "type": "query",
                "description": "Include total count of the collection in the pagination response"
              }
            ]
          },
          "docs": "| ⚠️  This endpoint is currently in BETA |\n|--|\n\nReturns relevant notes for a given company which includes directly attached notes and notes attached to persons on this company.\n\nYou can filter notes using the `filter` query parameter. The filter parameter is a string that you can specify conditions based on the following properties.\n| **Property Name**           | **Description**                                                 | **Type**   | **Allowed Operators**                | **Examples**  "
        }
      ]
    }
  ],
  "bundled": true
}