← Public packages
@kody/hubspot
Read HubSpot contacts, companies, deals, and tickets, with dry-run writes and generic CRM object reads.
src/get-ticket.ts
23 lines · 668 B · TypeScriptimport { getStandard, parseGetInput, type StandardGetInput } from './wrappers.ts'
/**
* Get one HubSpot ticket.
* @example
* import getTicket from 'kody:@kody/hubspot/get-ticket'
* const record = await getTicket({ id: '123' })
*/
export async function getTicket(input: StandardGetInput) {
return getStandard('tickets', input)
}
/**
* Get one HubSpot ticket.
* @example
* import getTicket from 'kody:@kody/hubspot/get-ticket'
* const record = await getTicket({ id: '123' })
*/
export default async function getTicketEntrypoint(
params: Partial<StandardGetInput> & Record<string, unknown> = {},
) {
return getTicket(parseGetInput(params, 'get-ticket'))
}