Hustle Public API

RESTful v3 API for programmatic access to resources within a Hustle account: agents, groups, leads, custom fields, tags, organizations, CRM integrations, and webhook registrations. Authenticates via the OAuth2 client-credentials flow and returns Bearer access tokens. Uses cursor-based pagination and HMAC signed webhook events for consent and message-status updates.

Documentation

Specifications

Other Resources

🔗
OAuthScopes
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/scopes/hustle-scopes.yml
🔗
Webhooks
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/asyncapi/hustle-webhooks.yml
🔗
ErrorCatalog
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/errors/hustle-problem-types.yml
🔗
Conventions
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/conventions/hustle-conventions.yml
🔗
Idempotency
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/conventions/hustle-conventions.yml
🔗
DataModel
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/data-model/hustle-data-model.yml
🔗
Conformance
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/conformance/hustle-conformance.yml
🔗
MCPServer
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/mcp/hustle-mcp.yml
🔗
Overlay
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/overlays/hustle-public-api-overlay.yaml
🔗
AgentSkill
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/skills/_index.yml
🔗
WellKnown
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/well-known/hustle-well-known.yml
🔗
LLMsTxt
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/llms/hustle-llms.txt
🔗
APIsJSON
https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/apis.yml

OpenAPI Specification

hustle-openapi-original.json Raw ↑
{"openapi":"3.1.0","info":{"title":"Hustle Public API","version":"v3","description":"The Hustle Public API exposes a RESTful interface to provide programmatic access to resources within your Hustle account. The API is defined using the OpenAPI specification (aka Swagger) which can be downloaded above and used to generate a client in various languages. This may help speed up integration with the API, but is not required."},"servers":[{"url":"/v3"}],"externalDocs":{"description":"Click here for a more in-depth user guide or links to prior versions of the api documentation.","url":"description.html"},"components":{"schemas":{"Agent":{"type":"object","properties":{"id":{"type":"string","description":"The ID of the agent."},"type":{"type":"string","enum":["agent"],"description":"The type of object the attached ID corresponds to."},"name":{"type":"string","description":"The display name of the agent."},"fullName":{"type":"string","description":"The full name of the agent."},"phoneNumber":{"type":"string","pattern":"^\\+[1-9]\\d{1,14}$|^\\d{5,6}$","description":"The phone number of the agent."},"organizationId":{"type":"string","description":"The ID of the organization the agent belongs to."},"groupId":{"type":"string","description":"The ID of the group the agent belongs to."},"createdAt":{"type":"string","description":"An ISO-8601 string representing the date the agent was created."}},"required":["id","type","name","fullName","organizationId","groupId","createdAt"],"additionalProperties":false,"description":"An agent represents someone that contacts leads on behalf of an organization."},"ErrorResponse":{"type":"object","properties":{"code":{"type":"number","description":"Error code; usually the status code."},"message":{"type":"string","description":"Error message detailing the error."},"hustleErrorCode":{"type":"string","description":"Sometimes available (generally with 422 responses). If the message is not descriptive enough to help identify the issue, pass this code to Hustle support."}},"required":["code","message"],"additionalProperties":false},"Custom Field":{"type":"object","properties":{"id":{"type":"string","description":"The ID of the custom field."},"type":{"type":"string","enum":["custom_field"],"description":"The type of object the attached ID corresponds to."},"name":{"type":"string","pattern":"^[_a-zA-Z]\\w*$","description":"The name of the custom field."},"agentVisible":{"type":"boolean","description":"Whether the custom field is visible to agents."},"organizationId":{"type":"string","description":"The organization this custom field is scoped to (if any)."},"createdAt":{"type":"string","description":"An ISO-8601 string representing the date the custom field was created."}},"required":["id","type","name","agentVisible","createdAt"],"additionalProperties":false,"description":"A custom field is a custom property that can be attached to a lead."},"Group":{"type":"object","properties":{"id":{"type":"string","description":"The ID of the group."},"type":{"type":"string","enum":["group"],"description":"The type of object the attached ID corresponds to."},"name":{"type":"string","description":"The name of the group."},"description":{"type":"string","description":"The user provided description of the group."},"countryCode":{"type":"string","enum":["US","CA","PR"],"description":"The country code of the country the group is registered in.","example":"US"},"active":{"type":"boolean","description":"Whether or not the group is active."},"location":{"type":"object","properties":{"label":{"type":"string","description":"The human readable location of the group.","example":"Denver, CO, USA"},"coordinates":{"type":"object","properties":{"lat":{"type":"number","description":"The latitude of the group location.","example":39.7392358},"lng":{"type":"number","description":"The longitude of the group location.","example":-104.990251}},"required":["lat","lng"],"additionalProperties":false,"description":"The coordinates that the group location is set to."}},"required":["label","coordinates"],"additionalProperties":false,"description":"The location of the group."},"organizationId":{"type":"string","description":"The organization this group belongs to."},"timezone":{"type":"string","description":"The timezone of the group. Represented as an IANA Zone ID.","example":"America/Denver"},"createdAt":{"type":"string","description":"An ISO-8601 string representing the date the group was created."}},"required":["id","type","name","countryCode","active","organizationId","timezone","createdAt"],"additionalProperties":false,"description":"A group belongs to an Organization and organizes leads/agents/goals."},"Integration":{"type":"object","properties":{"id":{"type":"string","description":"The ID of the integration."},"type":{"type":"string","enum":["integration"],"description":"The type of object the attached ID corresponds to."},"name":{"type":"string","description":"The name of the integration."},"integrationType":{"type":"string","enum":["bbluminate","evertrue","msdynamics","pdi","salesforce_managed_package","van","van_myvoters","webhook"],"description":"The type of integration."},"organizationId":{"type":"string","description":"The ID of the organization the integration belongs to."},"createdAt":{"type":"string","description":"An ISO-8601 string representing the date the integration was created."}},"required":["id","type","name","integrationType","organizationId","createdAt"],"additionalProperties":false,"description":"An integration represents a connection between Hustle data and an external service (such as Salesforce, VAN, or PDI)."},"PDIPatchIntegration":{"type":"object","properties":{"type":{"type":"string","enum":["updatePDICredentials"],"description":"This operation will update the credentials associated with an integration provided the credentials are valid."},"credentials":{"type":"object","properties":{"username":{"type":"string","description":"Username or email used to authenticate to the integration."},"password":{"type":"string","description":"Password used to authenticate to the integration."},"apiKey":{"type":"string","description":"apiKey used to authenticate to PDI."}},"required":["username","password","apiKey"],"additionalProperties":false}},"required":["type","credentials"],"additionalProperties":false},"VanPatchIntegration":{"type":"object","properties":{"type":{"type":"string","enum":["updateVANCredentials"],"description":"This operation will update the credentials associated with an integration provided the credentials are valid."},"credentials":{"type":"object","properties":{"applicationName":{"type":"string","description":"application name used to authenticate."},"apiKey":{"type":"string","description":"apiKey used to authenticate."}},"required":["applicationName","apiKey"],"additionalProperties":false}},"required":["type","credentials"],"additionalProperties":false},"VanMyVotersPatchIntegration":{"type":"object","properties":{"type":{"type":"string","enum":["updateVANMyVotersCredentials"],"description":"This operation will update the credentials associated with an integration provided the credentials are valid."},"credentials":{"type":"object","properties":{"applicationName":{"type":"string","description":"application name used to authenticate."},"apiKey":{"type":"string","description":"apiKey used to authenticate."}},"required":["applicationName","apiKey"],"additionalProperties":false}},"required":["type","credentials"],"additionalProperties":false},"PDICreateIntegration":{"type":"object","properties":{"type":{"type":"string","enum":["pdi"]},"name":{"type":"string","description":"Name of the integration to be created"},"credentials":{"type":"object","properties":{"username":{"type":"string","description":"Username or email used to authenticate to the integration."},"password":{"type":"string","description":"Password used to authenticate to the integration."},"apiKey":{"type":"string","description":"apiKey used to authenticate to PDI."}},"required":["username","password","apiKey"],"additionalProperties":false}},"required":["type","name","credentials"],"additionalProperties":false},"VanCreateIntegration":{"type":"object","properties":{"type":{"type":"string","enum":["van"]},"name":{"type":"string","description":"Name of the integration to be created"},"credentials":{"type":"object","properties":{"applicationName":{"type":"string","description":"application name used to authenticate."},"apiKey":{"type":"string","description":"apiKey used to authenticate."}},"required":["applicationName","apiKey"],"additionalProperties":false},"refKey":{"type":"string","description":"Key used for processing of saved list."}},"required":["type","name","credentials"],"additionalProperties":false},"VanMyVotersCreateIntegration":{"type":"object","properties":{"type":{"type":"string","enum":["van_myvoters"]},"name":{"type":"string","description":"Name of the integration to be created"},"credentials":{"type":"object","properties":{"applicationName":{"type":"string","description":"application name used to authenticate."},"apiKey":{"type":"string","description":"apiKey used to authenticate."}},"required":["applicationName","apiKey"],"additionalProperties":false},"refKey":{"type":"string","description":"Key used for processing of saved list."}},"required":["type","name","credentials"],"additionalProperties":false},"Lead":{"type":"object","properties":{"id":{"type":"string","description":"The ID of the lead."},"type":{"type":"string","enum":["lead"],"description":"The type of object the attached ID corresponds to."},"phoneNumber":{"type":"string","pattern":"^\\+[1-9]\\d{1,14}$|^\\d{5,6}$","description":"The phone number of the lead. The combination of organizationId and phoneNumber represent a lead. Attempting to insert a new lead with these existing values will overwrite the existing lead."},"organizationId":{"type":"string","description":"The ID of the organization the lead belongs to. The combination of organizationId and phoneNumber represent a lead. Attempting to insert a new lead with these existing values will overwrite the existing lead."},"activeGroupIds":{"type":"array","items":{"type":"string"},"description":"The IDs of the groups the lead belongs to where they are still active."},"inactiveGroupIds":{"type":"array","items":{"type":"string"},"description":"The IDs of the groups the lead belongs to where the lead is inactive. Because deleting a lead from a group is not allowed, the only way to stop a lead from receiving messages meant for a group is to make them inactive."},"customFields":{"type":"object","additionalProperties":{"type":"string"},"description":"The custom fields and associated values for the lead."},"firstName":{"type":"string","description":"The first name of the lead."},"lastName":{"type":"string","description":"The last name of the lead."},"notes":{"type":"string","description":"Notes about the lead."},"followUp":{"type":"string","description":"Follow up comments for the lead."},"email":{"type":"string","description":"The email of the lead."},"postalCode":{"type":"string","description":"The postal (AKA zip) code of the lead."},"phoneNumberType":{"type":"string","enum":["mobile","landline","voip","invalid"],"description":"The type of phone number of the lead. Older leads or leads that have not been messaged recently may not have this data available."},"tagIds":{"type":"array","items":{"type":"string"},"description":"The IDs of the tags that have been applied to the lead."},"globalOptedOut":{"type":"boolean","description":"Whether or not the lead has opted out of all messages. If this is true, the lead will not receive any messages."},"createdAt":{"type":"string","description":"An ISO-8601 string representing the date the agent was created."}},"required":["id","type","phoneNumber","organizationId","activeGroupIds","inactiveGroupIds","customFields","tagIds","globalOptedOut","createdAt"],"additionalProperties":false,"description":"A lead represents someone that messages and calls are sent to."},"MakeActiveInGroupOperation":{"type":"object","properties":{"type":{"type":"string","enum":["makeActiveInGroup"],"description":"This operation will make the lead active in the group and add the lead to a specified group if they are not already a part of it. This is a permanent addition since these leads have message history and other auditing requirements that make them impossible to permanently delete. The only way to stop texting a lead in a group is to make them inactive using the MakeInactiveInGroup operation."},"groupId":{"type":"string","description":"The ID of the group to reactivate the lead in or add the lead to."}},"required":["type","groupId"],"additionalProperties":false},"MakeInactiveInGroupOperation":{"type":"object","properties":{"type":{"type":"string","enum":["makeInactiveInGroup"],"description":"This operation will make the lead inactive in the specified group. Because deleting a lead from a group is not allowed since the lead has message history, the only way to stop a lead from receiving messages meant for a group is to make them inactive."},"groupId":{"type":"string","description":"The ID of the group to make the lead inactive in."}},"required":["type","groupId"],"additionalProperties":false},"VanExternalLeadSchema":{"type":"object","properties":{"integrationType":{"type":"string","enum":["van"]},"externalObject":{"type":"object","properties":{"version":{"type":"string","enum":["v4"]},"vanId":{"type":"string"},"vanPhoneId":{"type":"number"}},"required":["version","vanId"],"additionalProperties":false}},"required":["integrationType","externalObject"],"additionalProperties":false},"VanMyVotersExternalLeadSchema":{"type":"object","properties":{"integrationType":{"type":"string","enum":["van-myvoters"]},"externalObject":{"type":"object","properties":{"version":{"type":"string","enum":["v4"]},"vanId":{"type":"string"},"vanPhoneId":{"type":"number"}},"required":["version","vanId"],"additionalProperties":false}},"required":["integrationType","externalObject"],"additionalProperties":false},"EvertrueExternalLeadSchema":{"type":"object","properties":{"integrationType":{"type":"string","enum":["evertrue"]},"externalObject":{"type":"object","properties":{"version":{"type":"string","enum":["1.0"]},"remoteId":{"type":"string"}},"required":["version","remoteId"],"additionalProperties":false}},"required":["integrationType","externalObject"],"additionalProperties":false},"SalesforceExternalLeadSchema":{"type":"object","properties":{"integrationType":{"type":"string","enum":["salesforce"]},"externalObject":{"type":"object","properties":{"version":{"type":"string","enum":["41.0"]},"salesforceObjectType":{"type":"string"},"salesforceObjectId":{"type":"string"}},"required":["version","salesforceObjectType","salesforceObjectId"],"additionalProperties":false}},"required":["integrationType","externalObject"],"additionalProperties":false},"BbLuminateExternalLeadSchema":{"type":"object","properties":{"integrationType":{"type":"string","enum":["bbluminate"]},"externalObject":{"type":"object","properties":{"version":{"type":"string","enum":["1.0"]},"constituentId":{"type":"string"}},"required":["version","constituentId"],"additionalProperties":false}},"required":["integrationType","externalObject"],"additionalProperties":false},"AttachLeadToIntegrationOperation":{"type":"object","properties":{"type":{"type":"string","enum":["attachLeadToIntegration"],"description":"This operation will attach a lead in Hustle to a lead (or similar object) in an integration."},"integrationId":{"type":"string","description":"The ID of the integration to attach the lead to."},"external":{"oneOf":[{"$ref":"#/components/schemas/VanExternalLeadSchema"},{"$ref":"#/components/schemas/VanMyVotersExternalLeadSchema"},{"$ref":"#/components/schemas/EvertrueExternalLeadSchema"},{"$ref":"#/components/schemas/SalesforceExternalLeadSchema"},{"$ref":"#/components/schemas/BbLuminateExternalLeadSchema"}],"discriminator":{"propertyName":"integrationType","mapping":{"van":"#/components/schemas/VanExternalLeadSchema","van-myvoters":"#/components/schemas/VanMyVotersExternalLeadSchema","evertrue":"#/components/schemas/EvertrueExternalLeadSchema","salesforce":"#/components/schemas/SalesforceExternalLeadSchema","bbluminate":"#/components/schemas/BbLuminateExternalLeadSchema"}}}},"required":["type","integrationId","external"],"additionalProperties":false},"ApplyTagOperation":{"type":"object","properties":{"type":{"type":"string","enum":["applyTag"],"description":"This operation will attach a tag in an organization to a lead in that same organization."},"tagId":{"type":"string","description":"The ID of the tag to apply to the lead."}},"required":["type","tagId"],"additionalProperties":false},"RemoveTagOperation":{"type":"object","properties":{"type":{"type":"string","enum":["removeTag"],"description":"This operation will remove a tag form a lead."},"tagId":{"type":"string","description":"The ID of the tag to remove from the lead."}},"required":["type","tagId"],"additionalProperties":false},"SetCustomFieldOperation":{"type":"object","properties":{"type":{"type":"string","enum":["setCustomField"],"description":"This operation will set the value of a custom field on a lead."},"customFieldName":{"type":"string","description":"The label of the custom field to set. This must exist as a custom field in the organization."},"value":{"type":"string","description":"The value to set the custom field to."}},"required":["type","customFieldName","value"],"additionalProperties":false},"OptOutOperation":{"type":"object","properties":{"type":{"type":"string","enum":["optOut"],"description":"This operation will opt a lead out of receiving messages from Hustle. If account sync is enabled, all other leads in the account with the same number will also be opted out."},"tagId":{"type":"string","description":"The ID of the tag to apply to the lead when opting them out. This must be an OptOut tag."}},"required":["type"],"additionalProperties":false},"OptInOperation":{"type":"object","properties":{"type":{"type":"string","enum":["optIn"],"description":"This operation will opt a lead back in to receiving messages from Hustle. If account sync is enabled, all other leads in the account with the same number will also be opted in."}},"required":["type"],"additionalProperties":false},"Organization":{"type":"object","properties":{"id":{"type":"string","description":"The ID of the organization."},"type":{"type":"string","enum":["organization"],"description":"The type of object the attached ID corresponds to."},"name":{"type":"string","description":"The name of the organization."},"integrations":{"type":"array","items":{"type":"string"},"description":"The IDs of the integrations the organization owns."},"balances":{"type":"object","properties":{"smsBalance":{"type":"number","description":"The number of SMS messages the organization has remaining."},"mmsBalance":{"type":"number","description":"The number of MMS messages the organization has remaining."},"callBalance":{"type":"number","description":"The number of calls the organization has remaining."}},"required":["smsBalance","mmsBalance","callBalance"],"description":"The message and call balances for the organization. This property will only show up if the organization has these enabled."},"createdAt":{"type":"string","description":"An ISO-8601 string representing the date the organization was created."}},"required":["id","type","name","integrations","createdAt"],"additionalProperties":false,"description":"An organization owns multiple groups and is the entity leads are scoped to in Hustle."},"Tag":{"type":"object","properties":{"id":{"type":"string","description":"The tag's ID."},"type":{"type":"string","enum":["tag"],"description":"The type of this object."},"name":{"type":"string","description":"The tag name/label that shows up in the UI."},"organizationId":{"type":"string","description":"The organization this tag belongs to."},"createdAt":{"type":"string","description":"An ISO-8601 string representing the date the tag was created."},"agentVisibility":{"type":"string","enum":["LEAD_PROFILES","OPT_OUT","NEVER"],"description":"The context in which an agent can see and collect tags. \nLEAD_PROFILES: The default use. Agents will be able to see these while sending messages and use them to collect info about contacts. \nOPT_OUT: Specifically for opt-out reasons. Will only be displayed when agents opt out a contact. \nNEVER: Only for admins. Agents will never see this tag."}},"required":["id","type","name","createdAt","agentVisibility"],"additionalProperties":false,"description":"A tag represents a label that can be applied to a lead."},"WebhookOrganizationsScopeV1":{"type":"object","properties":{"type":{"type":"string","enum":["organizations"],"description":"Scope the webhook to leads in specific organizations."},"organizationIds":{"type":"array","items":{"type":"string"},"description":"Array of organization IDs to scope the webhook to."}},"required":["type","organizationIds"],"additionalProperties":false},"WebhookAccountScopeV1":{"type":"object","properties":{"type":{"type":"string","enum":["account"],"description":"Scope the webhook to leads in the entire account."}},"required":["type"],"additionalProperties":false},"ConsentUpdateV1Config":{"type":"object","properties":{"type":{"type":"string","enum":["consentUpdate-v1"],"description":"Consent Updates are sent when a lead updates their consent status to opt-in or opt-out of communications."},"scope":{"oneOf":[{"$ref":"#/components/schemas/WebhookOrganizationsScopeV1"},{"$ref":"#/components/schemas/WebhookAccountScopeV1"}],"discriminator":{"propertyName":"type","mapping":{"organizations":"#/components/schemas/WebhookOrganizationsScopeV1","account":"#/components/schemas/WebhookAccountScopeV1"}}},"includeOptOut":{"type":"boolean","description":"Whether to include opt-out events in the webhook."},"includeOptIn":{"type":"boolean","description":"Whether to include opt-in events in the webhook."}},"required":["type","scope","includeOptOut","includeOptIn"],"additionalProperties":false},"MessageStatusV1Config":{"type":"object","properties":{"type":{"type":"string","enum":["messageStatus-v1"],"description":"Message Status updates are sent when a message status changes (e.g., delivered, failed)."},"scope":{"oneOf":[{"$ref":"#/components/schemas/WebhookOrganizationsScopeV1"},{"$ref":"#/components/schemas/WebhookAccountScopeV1"}],"discriminator":{"propertyName":"type","mapping":{"organizations":"#/components/schemas/WebhookOrganizationsScopeV1","account":"#/components/schemas/WebhookAccountScopeV1"}}}},"required":["type","scope"],"additionalProperties":false},"WebhookConfig":{"oneOf":[{"$ref":"#/components/schemas/ConsentUpdateV1Config"},{"$ref":"#/components/schemas/MessageStatusV1Config"}],"discriminator":{"propertyName":"type","mapping":{"consentUpdate-v1":"#/components/schemas/ConsentUpdateV1Config","messageStatus-v1":"#/components/schemas/MessageStatusV1Config"}},"description":"The configuration object for the webhook."},"WebhookRegistration":{"type":"object","properties":{"id":{"type":"string","description":"The ID of the webhook registration."},"type":{"type":"string","enum":["webhook_registration"],"description":"The type of object the attached ID corresponds to."},"targetUrl":{"type":"string","format":"uri","description":"The URL that will receive webhook events."},"config":{"$ref":"#/components/schemas/WebhookConfig"},"createdAt":{"type":"string","description":"An ISO-8601 string representing the date the webhook registration was created."},"secretForHMAC":{"type":"boolean","description":"Whether a secret is currently active for HMAC signature verification of webhook events. We do not ever return the secret so if you have lost your copy, you will need to set a new one."}},"required":["id","type","targetUrl","config","createdAt","secretForHMAC"],"additionalProperties":false,"description":"A webhook registration defines when and where webhook events should be sent."}},"parameters":{}},"paths":{"/oauth/token":{"post":{"summary":"Create Access Token","description":"Your server-side script or backend application must authenticate to create an access token. Access tokens are used to authorize requests that read and write Hustle resources. To authenticate use your Hustle provided client_id and client_secret to make a request following the <a href=\"https://www.oauth.com/oauth2-servers/access-tokens/client-credentials/\">OAuth2 client credentials flow.</a>","tags":["Access Token"],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"grant_type":{"type":"string","enum":["client_credentials"]},"client_id":{"type":"string","format":"email"},"client_secret":{"type":"string"}},"required":["grant_type","client_id","client_secret"],"additionalProperties":false}}}},"responses":{"200":{"description":"Returns an OAuth access token. This token is used to authenticate requests to the Hustle API by appending it to the Authentication header as \"Bearer token_goes_here\".","content":{"application/json":{"schema":{"type":"object","properties":{"access_token":{"type":"string"},"token_type":{"type":"string","enum":["Bearer"]},"scope":{"type":"string"},"expires_in":{"type":"number"}},"required":["access_token","token_type","scope","expires_in"],"additionalProperties":false}}}}}}},"/agents":{"get":{"summary":"Get Agents","description":"Get a list of agents scoped by the query parameters.","tags":["Agents"],"parameters":[{"schema":{"type":"string","description":"Agent ID."},"required":false,"description":"Agent ID.","name":"id","in":"query"},{"schema":{"type":"string","description":"The ID of the Group the agent belongs to."},"required":false,"description":"The ID of the Group the agent belongs to.","name":"groupId","in":"query"},{"schema":{"type":"string","description":"Cursor for start of next set of items. Pass whatever you receive from the response to get the next elements in the array."},"required":false,"description":"Cursor for start of next set of items. Pass whatever you receive from the response to get the next elements in the array.","name":"cursor","in":"query"},{"schema":{"type":"number","maximum":1000,"minimum":1,"description":"Limit of items per page."},"required":false,"description":"Limit of items per page.","name":"limit","in":"query"}],"responses":{"200":{"description":"Returns a list of agents that match the query parameters.","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Agent"},"description":"List of agents that match the specified filter."},"cursor":{"type":["string","null"],"description":"Cursor for start of next set of items. If there were no items to return with the last cursor you passed, this will return null."},"hasMore":{"type":"boolean","description":"Whether there are more items to load past this cursor."}},"required":["items","cursor","hasMore"],"additionalProperties":false}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}},"post":{"summary":"Create Agent","description":"Create a new agent. This will send an email invite to the agent being created if they are not already a Hustle user.","tags":["Agents"],"requestBody":{"description":"The details of the agent being created. ","content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","description":"The display name of the agent."},"fullName":{"type":"string","description":"The full name of the agent."},"email":{"type":"string","format":"email","description":"The email of the agent - This will be used by the agent to log in."},"groupId":{"type":"string","description":"The ID of the group the agent will belong to."}},"required":["name","fullName","email","groupId"],"additionalProperties":false}}}},"responses":{"200":{"description":"Returns the created agent.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Agent"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/agents/{id}":{"put":{"summary":"Update Agent","description":"Update an existing agent.","tags":["Agents"],"parameters":[{"schema":{"type":"string","description":"The ID of the agent to update."},"required":true,"description":"The ID of the agent to update.","name":"id","in":"path"}],"requestBody":{"description":"The details of the agent to update. ","content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","description":"The display name of the agent."},"fullName":{"type":"string","description":"The full name of the agent."},"sendInvite":{"type":"boolean","description":"Whether this update should send a new email invite to the agent."}},"required":["name","fullName"],"additionalProperties":false}}}},"responses":{"200":{"description":"Returns the updated agent.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Agent"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"Not Found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"422":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/custom_fields":{"get":{"summary":"Get Custom Fields","description":"Get a list of custom fields scoped by the query parameters.","tags":["Custom Fields"],"parameters":[{"schema":{"type":"string","description":"Custom Field ID."},"required":false,"description":"Custom Field ID.","name":"id","in":"query"},{"schema":{"type":"string","description":"Organization ID. A lack of this property will look for all custom fields in the account, both account scoped and organization scoped."},"required":false,"description":"Organization ID. A lack of this property will look for all custom fields in the account, both account scoped and organization scoped.","name":"organizationId","in":"query"},{"schema":{"type":"string","description":"Cursor for start of next set of items. Pass whatever you receive from the response to get the next elements in the array."},"required":false,"description":"Cursor for start of next set of items. Pass whatever you receive from the response to get the next elements in the array.","name":"cursor","in":"query"},{"schema":{"type":"number","maximum":1000,"minimum":1,"description":"Limit of items per page."},"required":false,"description":"Limit of items per page.","name":"limit","in":"query"}],"responses":{"200":{"description":"Returns a list of agents that match the query parameters.","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/Custom Field"},"description":"List of custom fields that match the specified filter."},"cursor":{"type":["string","null"],"description":"Cursor for start of next set of items. If there were no items to return with the last cursor you passed, this will return null."},"hasMore":{"type":"boolean","description":"Whether there are more items to load past this cursor."}},"required":["items","cursor","hasMore"],"additionalProperties":false}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"40

# --- truncated at 32 KB (72 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/hustle/refs/heads/main/openapi/hustle-openapi-original.json