naftiko: 1.0.0-alpha2 info: label: HubSpot CRM Deals API — Associations description: 'HubSpot CRM Deals API — Associations. 3 operations. Lead operation: Hubspot List Deal Associations. Self-contained Naftiko capability covering one Hubspot business surface.' tags: - Hubspot - Associations created: '2026-05-19' modified: '2026-05-19' binds: - namespace: env keys: HUBSPOT_API_KEY: HUBSPOT_API_KEY capability: consumes: - type: http namespace: crm-deals-associations baseUri: https://api.hubapi.com description: HubSpot CRM Deals API — Associations business capability. Self-contained, no shared references. resources: - name: crm-v3-objects-deals-dealId-associations-toObjectType path: /crm/v3/objects/deals/{dealId}/associations/{toObjectType} operations: - name: listdealassociations method: GET description: Hubspot List Deal Associations outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: dealId in: path type: string description: The ID of the deal. required: true - name: toObjectType in: path type: string description: The type of associated object (e.g., contacts, companies). required: true - name: crm-v3-objects-deals-dealId-associations-toObjectType-toObjectId-associationType path: /crm/v3/objects/deals/{dealId}/associations/{toObjectType}/{toObjectId}/{associationType} operations: - name: createdealassociation method: PUT description: Hubspot Create a Deal Association outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: dealId in: path type: string description: The ID of the deal. required: true - name: toObjectType in: path type: string description: The type of the object to associate with. required: true - name: toObjectId in: path type: string description: The ID of the object to associate with. required: true - name: associationType in: path type: string description: The type of association to create. required: true - name: deletedealassociation method: DELETE description: Hubspot Delete a Deal Association outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: dealId in: path type: string description: The ID of the deal. required: true - name: toObjectType in: path type: string description: The type of the associated object. required: true - name: toObjectId in: path type: string description: The ID of the associated object. required: true - name: associationType in: path type: string description: The type of association to delete. required: true authentication: type: bearer token: '{{env.HUBSPOT_API_KEY}}' exposes: - type: rest namespace: crm-deals-associations-rest port: 8080 description: REST adapter for HubSpot CRM Deals API — Associations. One Spectral-compliant resource per consumed operation, prefixed with /v1. resources: - path: /v1/crm/v3/objects/deals/{dealid}/associations/{toobjecttype} name: crm-v3-objects-deals-dealid-associations-toobjecttype description: REST surface for crm-v3-objects-deals-dealId-associations-toObjectType. operations: - method: GET name: listdealassociations description: Hubspot List Deal Associations call: crm-deals-associations.listdealassociations with: dealId: rest.dealId toObjectType: rest.toObjectType outputParameters: - type: object mapping: $. - path: /v1/crm/v3/objects/deals/{dealid}/associations/{toobjecttype}/{toobjectid}/{associationtype} name: crm-v3-objects-deals-dealid-associations-toobjecttype-toobjectid-associationtype description: REST surface for crm-v3-objects-deals-dealId-associations-toObjectType-toObjectId-associationType. operations: - method: PUT name: createdealassociation description: Hubspot Create a Deal Association call: crm-deals-associations.createdealassociation with: dealId: rest.dealId toObjectType: rest.toObjectType toObjectId: rest.toObjectId associationType: rest.associationType outputParameters: - type: object mapping: $. - method: DELETE name: deletedealassociation description: Hubspot Delete a Deal Association call: crm-deals-associations.deletedealassociation with: dealId: rest.dealId toObjectType: rest.toObjectType toObjectId: rest.toObjectId associationType: rest.associationType outputParameters: - type: object mapping: $. - type: mcp namespace: crm-deals-associations-mcp port: 9090 transport: http description: MCP adapter for HubSpot CRM Deals API — Associations. One tool per consumed operation, routed inline through this capability's consumes block. tools: - name: hubspot-list-deal-associations description: Hubspot List Deal Associations hints: readOnly: true destructive: false idempotent: true call: crm-deals-associations.listdealassociations with: dealId: tools.dealId toObjectType: tools.toObjectType outputParameters: - type: object mapping: $. - name: hubspot-create-deal-association description: Hubspot Create a Deal Association hints: readOnly: false destructive: false idempotent: true call: crm-deals-associations.createdealassociation with: dealId: tools.dealId toObjectType: tools.toObjectType toObjectId: tools.toObjectId associationType: tools.associationType outputParameters: - type: object mapping: $. - name: hubspot-delete-deal-association description: Hubspot Delete a Deal Association hints: readOnly: false destructive: true idempotent: true call: crm-deals-associations.deletedealassociation with: dealId: tools.dealId toObjectType: tools.toObjectType toObjectId: tools.toObjectId associationType: tools.associationType outputParameters: - type: object mapping: $.