openapi: 3.1.0 info: title: API Endpoints subpackage_activities subpackage_customFieldsShared API version: 1.0.0 servers: - url: https://api.close.com/api/v1 tags: - name: subpackage_customFieldsShared paths: /custom_field/shared/: get: operationId: list summary: List Shared Custom Fields description: List all the shared custom fields for your organization. tags: - subpackage_customFieldsShared parameters: - name: _fields in: query description: Comma-separated list of fields to include in the response. required: false schema: type: string - name: Authorization in: header description: Use your API key as the username and leave the password empty. required: true schema: type: string responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/custom_fields.shared_list_Response_200' '400': description: Bad request content: application/json: schema: description: Any type '401': description: Unauthorized content: application/json: schema: description: Any type '404': description: Not found content: application/json: schema: description: Any type post: operationId: create summary: Create a new Shared Custom Field tags: - subpackage_customFieldsShared parameters: - name: Authorization in: header description: Use your API key as the username and leave the password empty. required: true schema: type: string responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/custom_fields.shared_create_Response_200' '400': description: Bad request content: application/json: schema: description: Any type '401': description: Unauthorized content: application/json: schema: description: Any type '404': description: Not found content: application/json: schema: description: Any type requestBody: content: application/json: schema: description: Any type /custom_field/shared/{id}/: get: operationId: get summary: Fetch Shared Custom Field's details tags: - subpackage_customFieldsShared parameters: - name: id in: path required: true schema: type: string - name: _fields in: query description: Comma-separated list of fields to include in the response. required: false schema: type: string - name: Authorization in: header description: Use your API key as the username and leave the password empty. required: true schema: type: string responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/custom_fields.shared_get_Response_200' '400': description: Bad request content: application/json: schema: description: Any type '401': description: Unauthorized content: application/json: schema: description: Any type '404': description: Not found content: application/json: schema: description: Any type put: operationId: update summary: Update a Shared Custom Field description: 'You can rename it or update the options for a "choices" field type. The updated name will immediately appear in the Close UI and only valid values for the updated `choices` will be returned by the Lead/Contact/Custom Activity APIs. The `type` value cannot be changed.' tags: - subpackage_customFieldsShared parameters: - name: id in: path required: true schema: type: string - name: Authorization in: header description: Use your API key as the username and leave the password empty. required: true schema: type: string responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/custom_fields.shared_update_Response_200' '400': description: Bad request content: application/json: schema: description: Any type '401': description: Unauthorized content: application/json: schema: description: Any type '404': description: Not found content: application/json: schema: description: Any type requestBody: content: application/json: schema: description: Any type delete: operationId: delete summary: Delete a Shared Custom Field description: Delete a shared custom field and all its associations. The field will immediately disappear from API responses and values on all associated object types will be permanently removed. tags: - subpackage_customFieldsShared parameters: - name: id in: path required: true schema: type: string - name: Authorization in: header description: Use your API key as the username and leave the password empty. required: true schema: type: string responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/custom_fields.shared_delete_Response_200' '400': description: Bad request content: application/json: schema: description: Any type '401': description: Unauthorized content: application/json: schema: description: Any type '404': description: Not found content: application/json: schema: description: Any type /custom_field/shared/{scf_id}/association/: post: operationId: create-association summary: Associate a Shared Custom Field with an object type description: "Associates a Shared Custom Field with an object type such as Lead, Contact, or Custom Activity Type. Once associated, the Shared Custom Field can be set on objects of that type.\n\nThis endpoint accepts the following attributes:\n\n- `object_type` – can be one of: `lead`, `contact`, `opportunity`, `custom_activity_type`,\n `custom_object_type`.\n- `custom_activity_type_id` – ID of the Custom Activity Type that you want to\n associate this Shared Field with. Only relevant if you chose the `object_type` of `custom_activity_type`.\n- `custom_object_type_id` – ID of the Custom Object Type that you want to\n associate this Shared Field with. Only relevant if you chose the `object_type` of `custom_object_type`.\n- `editable_with_roles` – list of [Roles](https://developer.close.com/api/resources/roles) that can edit the values of\n this Field on the given object. Note that this is a per-association setting, meaning that editing of the Shared Custom Field can be restricted on one object and not restricted on another.\n- `required` – whether a value *must* be provided for this Field on the given\n object. Only relevant if you chose the `object_type` of `custom_activity_type` or `custom_object_type`. Note that this is a per-association setting, meaning that this Shared Custom Field can be required on one object and not required on another." tags: - subpackage_customFieldsShared parameters: - name: scf_id in: path required: true schema: type: string - name: Authorization in: header description: Use your API key as the username and leave the password empty. required: true schema: type: string responses: '201': description: Successful response content: application/json: schema: $ref: '#/components/schemas/custom_fields.shared_createAssociation_Response_201' '400': description: Bad request content: application/json: schema: description: Any type '401': description: Unauthorized content: application/json: schema: description: Any type '404': description: Not found content: application/json: schema: description: Any type requestBody: content: application/json: schema: description: Any type /custom_field/shared/{scf_id}/association/{object_type}/: get: operationId: get-association summary: Fetch a Shared Custom Field Association tags: - subpackage_customFieldsShared parameters: - name: scf_id in: path required: true schema: type: string - name: object_type in: path required: true schema: type: string - name: Authorization in: header description: Use your API key as the username and leave the password empty. required: true schema: type: string responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/custom_fields.shared_getAssociation_Response_200' '400': description: Bad request content: application/json: schema: description: Any type '401': description: Unauthorized content: application/json: schema: description: Any type '404': description: Not found content: application/json: schema: description: Any type put: operationId: update-association summary: Update an existing Shared Custom Field Association description: "You can change the `required` or the `editable_with_roles` attributes. Everything else cannot be changed.\n\nThe `object_type` in the URL can be either:\n\n- `lead` when editing the association with the Lead object.\n- `contact` when editing the association with the Contact object.\n- `opportunity` when editing the association with the Opportunity object.\n- `custom_activity_type/` when editing the association with a specific\n Custom Activity Type.\n- `custom_object_type/` when editing the association with a specific\n Custom Object Type." tags: - subpackage_customFieldsShared parameters: - name: scf_id in: path required: true schema: type: string - name: object_type in: path required: true schema: type: string - name: Authorization in: header description: Use your API key as the username and leave the password empty. required: true schema: type: string responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/custom_fields.shared_updateAssociation_Response_200' '400': description: Bad request content: application/json: schema: description: Any type '401': description: Unauthorized content: application/json: schema: description: Any type '404': description: Not found content: application/json: schema: description: Any type requestBody: content: application/json: schema: description: Any type delete: operationId: delete-association summary: Disassociate a Shared Custom Field from an object type description: 'Remove the association between a shared custom field and an object type. The field will immediately disappear from API responses for that object type and all stored values will be permanently deleted. The `object_type` in the URL can be `lead`, `contact`, `opportunity`, `custom_activity_type/`, or `custom_object_type/`. If the field was `required` on the associated type, removing the association also removes that requirement.' tags: - subpackage_customFieldsShared parameters: - name: scf_id in: path required: true schema: type: string - name: object_type in: path required: true schema: type: string - name: Authorization in: header description: Use your API key as the username and leave the password empty. required: true schema: type: string responses: '204': description: No content content: application/json: schema: type: object properties: {} '400': description: Bad request content: application/json: schema: description: Any type '401': description: Unauthorized content: application/json: schema: description: Any type '404': description: Not found content: application/json: schema: description: Any type components: schemas: custom_fields.shared_get_Response_200: type: object properties: {} description: Empty response body title: custom_fields.shared_get_Response_200 custom_fields.shared_getAssociation_Response_200: type: object properties: {} description: Empty response body title: custom_fields.shared_getAssociation_Response_200 custom_fields.shared_create_Response_200: type: object properties: {} description: Empty response body title: custom_fields.shared_create_Response_200 custom_fields.shared_update_Response_200: type: object properties: {} description: Empty response body title: custom_fields.shared_update_Response_200 custom_fields.shared_createAssociation_Response_201: type: object properties: {} description: Empty response body title: custom_fields.shared_createAssociation_Response_201 custom_fields.shared_delete_Response_200: type: object properties: {} description: Empty response body title: custom_fields.shared_delete_Response_200 custom_fields.shared_updateAssociation_Response_200: type: object properties: {} description: Empty response body title: custom_fields.shared_updateAssociation_Response_200 custom_fields.shared_list_Response_200: type: object properties: {} description: Empty response body title: custom_fields.shared_list_Response_200 securitySchemes: ApiKeyAuth: type: http scheme: basic description: Use your API key as the username and leave the password empty. OAuth2: type: http scheme: bearer