mailmeteor 0.0.66 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +125 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +370 -27
- package/dist/index.mjs +125 -5
- package/dist/index.mjs.map +1 -1
- package/dist/types/generated-sdk/index.d.ts +2 -2
- package/dist/types/generated-sdk/index.d.ts.map +1 -1
- package/dist/types/generated-sdk/sdk.gen.d.ts +54 -3
- package/dist/types/generated-sdk/sdk.gen.d.ts.map +1 -1
- package/dist/types/generated-sdk/types.gen.d.ts +292 -25
- package/dist/types/generated-sdk/types.gen.d.ts.map +1 -1
- package/dist/types/index.d.ts +2 -1
- package/dist/types/index.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1058,6 +1058,22 @@ class HeyApiRegistry11 {
|
|
|
1058
1058
|
}
|
|
1059
1059
|
}
|
|
1060
1060
|
class HeyApiRegistry12 {
|
|
1061
|
+
constructor() {
|
|
1062
|
+
this.defaultKey = 'default';
|
|
1063
|
+
this.instances = new Map();
|
|
1064
|
+
}
|
|
1065
|
+
get(key) {
|
|
1066
|
+
const instance = this.instances.get(key ?? this.defaultKey);
|
|
1067
|
+
if (!instance) {
|
|
1068
|
+
throw new Error(`No SDK client found. Create one with "new Automations2()" to fix this error.`);
|
|
1069
|
+
}
|
|
1070
|
+
return instance;
|
|
1071
|
+
}
|
|
1072
|
+
set(value, key) {
|
|
1073
|
+
this.instances.set(key ?? this.defaultKey, value);
|
|
1074
|
+
}
|
|
1075
|
+
}
|
|
1076
|
+
class HeyApiRegistry13 {
|
|
1061
1077
|
constructor() {
|
|
1062
1078
|
this.defaultKey = 'default';
|
|
1063
1079
|
this.instances = new Map();
|
|
@@ -1695,7 +1711,7 @@ class PipelineConversations extends HeyApiClient {
|
|
|
1695
1711
|
});
|
|
1696
1712
|
}
|
|
1697
1713
|
listMessages(pipeline_conversation_id, parameters, options) {
|
|
1698
|
-
const params = buildClientParams([pipeline_conversation_id, parameters], [{ in: 'path', key: 'pipeline_conversation_id' }, { args: [{ in: 'query', key: 'owner' }] }]);
|
|
1714
|
+
const params = buildClientParams([pipeline_conversation_id, parameters], [{ in: 'path', key: 'pipeline_conversation_id' }, { args: [{ in: 'query', key: 'owner' }, { in: 'query', key: 'format' }] }]);
|
|
1699
1715
|
return (options?.client ?? this.client).get({
|
|
1700
1716
|
responseStyle: 'data',
|
|
1701
1717
|
url: '/pipeline_conversations/{pipeline_conversation_id}/messages',
|
|
@@ -1844,13 +1860,26 @@ class Integrations extends HeyApiClient {
|
|
|
1844
1860
|
...params
|
|
1845
1861
|
});
|
|
1846
1862
|
}
|
|
1847
|
-
disconnectAccount(integration_id, account_id, options) {
|
|
1848
|
-
const params = buildClientParams([
|
|
1863
|
+
disconnectAccount(integration_id, account_id, parameters, options) {
|
|
1864
|
+
const params = buildClientParams([
|
|
1865
|
+
integration_id,
|
|
1866
|
+
account_id,
|
|
1867
|
+
parameters
|
|
1868
|
+
], [
|
|
1869
|
+
{ in: 'path', key: 'integration_id' },
|
|
1870
|
+
{ in: 'path', key: 'account_id' },
|
|
1871
|
+
{ args: [{ in: 'body', key: 'reason' }] }
|
|
1872
|
+
]);
|
|
1849
1873
|
return (options?.client ?? this.client).post({
|
|
1850
1874
|
responseStyle: 'data',
|
|
1851
1875
|
url: '/integrations/{integration_id}/accounts/{account_id}/disconnect',
|
|
1852
1876
|
...options,
|
|
1853
|
-
...params
|
|
1877
|
+
...params,
|
|
1878
|
+
headers: {
|
|
1879
|
+
'Content-Type': 'application/json',
|
|
1880
|
+
...options?.headers,
|
|
1881
|
+
...params.headers
|
|
1882
|
+
}
|
|
1854
1883
|
});
|
|
1855
1884
|
}
|
|
1856
1885
|
}
|
|
@@ -1903,6 +1932,96 @@ class Jobs2 extends HeyApiClient {
|
|
|
1903
1932
|
}
|
|
1904
1933
|
}
|
|
1905
1934
|
Jobs2.__registry = new HeyApiRegistry11();
|
|
1935
|
+
class Automations extends HeyApiClient {
|
|
1936
|
+
list(parameters, options) {
|
|
1937
|
+
const params = buildClientParams([parameters], [{ args: [
|
|
1938
|
+
{ in: 'query', key: 'owner' },
|
|
1939
|
+
{ in: 'query', key: 'status' },
|
|
1940
|
+
{ in: 'query', key: 'limit' },
|
|
1941
|
+
{ in: 'query', key: 'starting_after' },
|
|
1942
|
+
{ in: 'query', key: 'ending_before' }
|
|
1943
|
+
] }]);
|
|
1944
|
+
return (options?.client ?? this.client).get({
|
|
1945
|
+
responseStyle: 'data',
|
|
1946
|
+
url: '/automations',
|
|
1947
|
+
...options,
|
|
1948
|
+
...params
|
|
1949
|
+
});
|
|
1950
|
+
}
|
|
1951
|
+
create(parameters, options) {
|
|
1952
|
+
const params = buildClientParams([parameters], [{ args: [
|
|
1953
|
+
{ in: 'body', key: 'owner' },
|
|
1954
|
+
{ in: 'body', key: 'name' },
|
|
1955
|
+
{ in: 'body', key: 'draft_definition' }
|
|
1956
|
+
] }]);
|
|
1957
|
+
return (options?.client ?? this.client).post({
|
|
1958
|
+
responseStyle: 'data',
|
|
1959
|
+
url: '/automations',
|
|
1960
|
+
...options,
|
|
1961
|
+
...params,
|
|
1962
|
+
headers: {
|
|
1963
|
+
'Content-Type': 'application/json',
|
|
1964
|
+
...options?.headers,
|
|
1965
|
+
...params.headers
|
|
1966
|
+
}
|
|
1967
|
+
});
|
|
1968
|
+
}
|
|
1969
|
+
count(parameters, options) {
|
|
1970
|
+
const params = buildClientParams([parameters], [{ args: [{ in: 'query', key: 'owner' }, { in: 'query', key: 'status' }] }]);
|
|
1971
|
+
return (options?.client ?? this.client).get({
|
|
1972
|
+
responseStyle: 'data',
|
|
1973
|
+
url: '/automations/count',
|
|
1974
|
+
...options,
|
|
1975
|
+
...params
|
|
1976
|
+
});
|
|
1977
|
+
}
|
|
1978
|
+
del(automation_id, parameters, options) {
|
|
1979
|
+
const params = buildClientParams([automation_id, parameters], [{ in: 'path', key: 'automation_id' }, { args: [{ in: 'query', key: 'owner' }] }]);
|
|
1980
|
+
return (options?.client ?? this.client).delete({
|
|
1981
|
+
responseStyle: 'data',
|
|
1982
|
+
url: '/automations/{automation_id}',
|
|
1983
|
+
...options,
|
|
1984
|
+
...params
|
|
1985
|
+
});
|
|
1986
|
+
}
|
|
1987
|
+
retrieve(automation_id, parameters, options) {
|
|
1988
|
+
const params = buildClientParams([automation_id, parameters], [{ in: 'path', key: 'automation_id' }, { args: [{ in: 'query', key: 'owner' }] }]);
|
|
1989
|
+
return (options?.client ?? this.client).get({
|
|
1990
|
+
responseStyle: 'data',
|
|
1991
|
+
url: '/automations/{automation_id}',
|
|
1992
|
+
...options,
|
|
1993
|
+
...params
|
|
1994
|
+
});
|
|
1995
|
+
}
|
|
1996
|
+
update(automation_id, parameters, options) {
|
|
1997
|
+
const params = buildClientParams([automation_id, parameters], [{ in: 'path', key: 'automation_id' }, { args: [
|
|
1998
|
+
{ in: 'body', key: 'owner' },
|
|
1999
|
+
{ in: 'body', key: 'name' },
|
|
2000
|
+
{ in: 'body', key: 'draft_definition' }
|
|
2001
|
+
] }]);
|
|
2002
|
+
return (options?.client ?? this.client).patch({
|
|
2003
|
+
responseStyle: 'data',
|
|
2004
|
+
url: '/automations/{automation_id}',
|
|
2005
|
+
...options,
|
|
2006
|
+
...params,
|
|
2007
|
+
headers: {
|
|
2008
|
+
'Content-Type': 'application/json',
|
|
2009
|
+
...options?.headers,
|
|
2010
|
+
...params.headers
|
|
2011
|
+
}
|
|
2012
|
+
});
|
|
2013
|
+
}
|
|
2014
|
+
}
|
|
2015
|
+
class Automations2 extends HeyApiClient {
|
|
2016
|
+
constructor(args) {
|
|
2017
|
+
super(args);
|
|
2018
|
+
Automations2.__registry.set(this, args?.key);
|
|
2019
|
+
}
|
|
2020
|
+
get automations() {
|
|
2021
|
+
return this._automations ?? (this._automations = new Automations({ client: this.client }));
|
|
2022
|
+
}
|
|
2023
|
+
}
|
|
2024
|
+
Automations2.__registry = new HeyApiRegistry12();
|
|
1906
2025
|
class Default extends HeyApiClient {
|
|
1907
2026
|
constructor(args) {
|
|
1908
2027
|
super(args);
|
|
@@ -1916,7 +2035,7 @@ class Default extends HeyApiClient {
|
|
|
1916
2035
|
});
|
|
1917
2036
|
}
|
|
1918
2037
|
}
|
|
1919
|
-
Default.__registry = new
|
|
2038
|
+
Default.__registry = new HeyApiRegistry13();
|
|
1920
2039
|
|
|
1921
2040
|
function querySerializer(query) {
|
|
1922
2041
|
const parts = [];
|
|
@@ -1976,6 +2095,7 @@ class Mailmeteor {
|
|
|
1976
2095
|
this.integrations = new Integrations({ client: this.client });
|
|
1977
2096
|
this.pipelineConversations = new PipelineConversations({ client: this.client });
|
|
1978
2097
|
this.jobs = new Jobs({ client: this.client });
|
|
2098
|
+
this.automations = new Automations({ client: this.client });
|
|
1979
2099
|
}
|
|
1980
2100
|
setApiKey(key) {
|
|
1981
2101
|
const currentConfig = this.client.getConfig();
|