@great-detail/support-sdk
Advanced tools
Comparing version 0.3.0 to 0.3.1
#!/usr/bin/env node | ||
import{a as r}from"./chunk-MIIHAFPV.js";import"./chunk-O5KZWMF7.js";r.parseAsync(process.argv); | ||
import{a as r}from"./chunk-NVKVNSH6.js";import"./chunk-HFYCS3BA.js";r.parseAsync(process.argv); |
import { Command } from 'commander'; | ||
import { C as Client } from '../index-ng6eKA5J.js'; | ||
import { C as Client } from '../index-BZ58JQ7A.js'; | ||
import { Options as Options$1 } from 'ora'; | ||
@@ -4,0 +4,0 @@ import 'ky'; |
@@ -1,1 +0,1 @@ | ||
import{a}from"../chunk-MIIHAFPV.js";import"../chunk-O5KZWMF7.js";export{a as default}; | ||
import{a}from"../chunk-NVKVNSH6.js";import"../chunk-HFYCS3BA.js";export{a as default}; |
@@ -1,3 +0,3 @@ | ||
import { A as Authentication } from './index-ng6eKA5J.js'; | ||
export { C as Client, b as CreateBoilerplateCategoryBoilerplateResponsePayload, e as CreateBoilerplateCategoryResponsePayload, F as CreateContactNoteResponsePayload, j as CreateContactResponsePayload, H as CreateConversationNoteResponsePayload, B as CreateCorrectionResponsePayload, s as CreateLabelResponsePayload, E as CreateResponseResponsePayload, D as DeleteLabelResponsePayload, f as GetBoilerplateCategoryResponsePayload, G as GetBoilerplateResponsePayload, k as GetContactResponsePayload, o as GetConversationResponsePayload, t as GetLabelResponsePayload, y as GetModelResponsePayload, I as GetNoteResponsePayload, N as GetSourceResponsePayload, L as ListActionsResponsePayload, g as ListBoilerplateCategoriesResponsePayload, c as ListBoilerplateCategoryBoilerplatesResponsePayload, d as ListBoilerplatesResponsePayload, i as ListChannelsResponsePayload, J as ListContactNotesResponsePayload, l as ListContactsResponsePayload, w as ListConversationMessagesResponsePayload, K as ListConversationNotesResponsePayload, p as ListConversationsResponsePayload, m as ListLabelContactsResponsePayload, q as ListLabelConversationsResponsePayload, u as ListLabelsResponsePayload, x as ListMessagesResponsePayload, z as ListModelsResponsePayload, P as ListSourcesResponsePayload, O as Options, R as RequestFilterable, a as TransportOptions, h as UpdateBoilerplateCategoryResponsePayload, U as UpdateBoilerplateResponsePayload, n as UpdateContactResponsePayload, r as UpdateConversationResponsePayload, v as UpdateLabelResponsePayload, M as UpdateNoteResponsePayload, C as default } from './index-ng6eKA5J.js'; | ||
import { A as Authentication } from './index-BZ58JQ7A.js'; | ||
export { C as Client, b as CreateBoilerplateCategoryBoilerplateResponsePayload, e as CreateBoilerplateCategoryResponsePayload, F as CreateContactNoteResponsePayload, j as CreateContactResponsePayload, H as CreateConversationNoteResponsePayload, B as CreateCorrectionResponsePayload, s as CreateLabelResponsePayload, E as CreateResponseResponsePayload, D as DeleteLabelResponsePayload, f as GetBoilerplateCategoryResponsePayload, G as GetBoilerplateResponsePayload, k as GetContactResponsePayload, o as GetConversationResponsePayload, t as GetLabelResponsePayload, y as GetModelResponsePayload, I as GetNoteResponsePayload, N as GetSourceResponsePayload, L as ListActionsResponsePayload, g as ListBoilerplateCategoriesResponsePayload, c as ListBoilerplateCategoryBoilerplatesResponsePayload, d as ListBoilerplatesResponsePayload, i as ListChannelsResponsePayload, J as ListContactNotesResponsePayload, l as ListContactsResponsePayload, w as ListConversationMessagesResponsePayload, K as ListConversationNotesResponsePayload, p as ListConversationsResponsePayload, m as ListLabelContactsResponsePayload, q as ListLabelConversationsResponsePayload, u as ListLabelsResponsePayload, x as ListMessagesResponsePayload, z as ListModelsResponsePayload, P as ListSourcesResponsePayload, O as Options, R as RequestFilterable, a as TransportOptions, h as UpdateBoilerplateCategoryResponsePayload, U as UpdateBoilerplateResponsePayload, n as UpdateContactResponsePayload, r as UpdateConversationResponsePayload, v as UpdateLabelResponsePayload, M as UpdateNoteResponsePayload, C as default } from './index-BZ58JQ7A.js'; | ||
import 'ky'; | ||
@@ -224,2 +224,23 @@ import 'zod'; | ||
type ListContactConversationsResponsePayload = { | ||
conversations: { | ||
id: string; | ||
name?: string; | ||
hasEnded: boolean; | ||
conversationStatus: "AwaitingContactConversationStatus" | "AwaitingAgentConversationStatus" | "ResolvedConversationStatus" | "ClosedConversationStatus"; | ||
accountChannel: string; | ||
createdAt: string; | ||
updatedAt: string; | ||
}[]; | ||
}; | ||
/** | ||
* Great Detail Support System. | ||
* | ||
* @copyright 2024 Great Detail Ltd | ||
* @author Great Detail Ltd <info@greatdetail.com> | ||
* @author Dom Webber <dom.webber@greatdetail.com> | ||
* @see https://greatdetail.com | ||
*/ | ||
type CreateContactSubscriptionResponsePayload = { | ||
@@ -233,2 +254,2 @@ subscription: { | ||
export { type CreateContactSubscriptionResponsePayload, DEFAULT_SUPPORT_BASE_URL, index as Error, KeyAuthentication, PublicAuthentication, TokenAuthentication }; | ||
export { type CreateContactSubscriptionResponsePayload, DEFAULT_SUPPORT_BASE_URL, index as Error, KeyAuthentication, type ListContactConversationsResponsePayload, PublicAuthentication, TokenAuthentication }; |
@@ -1,1 +0,1 @@ | ||
import{a as d,b as g,c as s,d as n,e as a,f as p,g as f,h as m,i as u,j as c,k as l,l as x,m as A,n as h,o as _}from"./chunk-O5KZWMF7.js";var E={};d(E,{AuthError:()=>m,AuthenticationError:()=>u,AuthorizationError:()=>c,LogicError:()=>l,NetworkError:()=>x,SupportError:()=>f,ValidationError:()=>A});var t=class o{static DEFAULT_NAME=s;name;#r;constructor({name:r=process.env[p]??o.DEFAULT_NAME,key:i=process.env[a]}={}){if(!i)throw new Error("API Key option must be specified when using Key Authentication");this.name=r,this.#r=i}async filter(){return{headers:this.getHeaders()}}getHeaders(){return{Authorization:`Basic ${btoa(this.name+":"+this.#r)}`}}};var e=class{#r;constructor({token:r=process.env[n]}={}){if(!r)throw new Error("Access Token option must be specified when using Token Authentication");this.#r=r}async filter(){return{headers:this.getHeaders()}}getHeaders(){return{Authorization:`Bearer ${this.#r}`}}};export{h as Client,g as DEFAULT_SUPPORT_BASE_URL,E as Error,t as KeyAuthentication,_ as PublicAuthentication,e as TokenAuthentication,h as default}; | ||
import{a as d,b as g,c as s,d as n,e as a,f as p,g as f,h as m,i as u,j as c,k as l,l as x,m as A,n as h,o as _}from"./chunk-HFYCS3BA.js";var E={};d(E,{AuthError:()=>m,AuthenticationError:()=>u,AuthorizationError:()=>c,LogicError:()=>l,NetworkError:()=>x,SupportError:()=>f,ValidationError:()=>A});var t=class o{static DEFAULT_NAME=s;name;#r;constructor({name:r=process.env[p]??o.DEFAULT_NAME,key:i=process.env[a]}={}){if(!i)throw new Error("API Key option must be specified when using Key Authentication");this.name=r,this.#r=i}async filter(){return{headers:this.getHeaders()}}getHeaders(){return{Authorization:`Basic ${btoa(this.name+":"+this.#r)}`}}};var e=class{#r;constructor({token:r=process.env[n]}={}){if(!r)throw new Error("Access Token option must be specified when using Token Authentication");this.#r=r}async filter(){return{headers:this.getHeaders()}}getHeaders(){return{Authorization:`Bearer ${this.#r}`}}};export{h as Client,g as DEFAULT_SUPPORT_BASE_URL,E as Error,t as KeyAuthentication,_ as PublicAuthentication,e as TokenAuthentication,h as default}; |
{ | ||
"name": "@great-detail/support-sdk", | ||
"version": "0.3.0", | ||
"version": "0.3.1", | ||
"type": "module", | ||
@@ -51,3 +51,3 @@ "description": "JavaScript SDK for the Great Detail Support System", | ||
"jest": "cross-env NODE_OPTIONS=\"$NODE_OPTIONS --experimental-vm-modules\" jest --passWithNoTests", | ||
"lint": "npm-run-all eslint typecheck publint prettier", | ||
"lint": "npm-run-all --parallel eslint typecheck publint prettier", | ||
"lint:dev": "npm-run-all eslint:dev typecheck publint prettier:dev", | ||
@@ -54,0 +54,0 @@ "prerelease": "npm-run-all build", |
@@ -119,4 +119,4 @@ /** | ||
create: new CreateContact(this._transport), | ||
vcf: { | ||
get: new GetContactVCFURL(this._transport), | ||
conversations: { | ||
list: new ListLabelConversations(this._transport), | ||
}, | ||
@@ -127,2 +127,5 @@ note: { | ||
}, | ||
vcf: { | ||
get: new GetContactVCFURL(this._transport), | ||
}, | ||
}; | ||
@@ -129,0 +132,0 @@ } |
@@ -14,1 +14,2 @@ /** | ||
export { type UpdateConversationResponsePayload } from "./UpdateConversation.js"; | ||
export { type ListContactConversationsResponsePayload } from "./ListContactConversations.js"; |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
294981
103
5204