@mobilerun/sdk 5.3.0 → 5.4.0
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/CHANGELOG.md +8 -0
- package/client.d.mts +3 -0
- package/client.d.mts.map +1 -1
- package/client.d.ts +3 -0
- package/client.d.ts.map +1 -1
- package/client.js +3 -0
- package/client.js.map +1 -1
- package/client.mjs +3 -0
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/index.d.mts +1 -0
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +1 -0
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +3 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -0
- package/resources/index.mjs.map +1 -1
- package/resources/mailboxes/index.d.mts +3 -0
- package/resources/mailboxes/index.d.mts.map +1 -0
- package/resources/mailboxes/index.d.ts +3 -0
- package/resources/mailboxes/index.d.ts.map +1 -0
- package/resources/mailboxes/index.js +9 -0
- package/resources/mailboxes/index.js.map +1 -0
- package/resources/mailboxes/index.mjs +4 -0
- package/resources/mailboxes/index.mjs.map +1 -0
- package/resources/mailboxes/mailboxes.d.mts +366 -0
- package/resources/mailboxes/mailboxes.d.mts.map +1 -0
- package/resources/mailboxes/mailboxes.d.ts +366 -0
- package/resources/mailboxes/mailboxes.d.ts.map +1 -0
- package/resources/mailboxes/mailboxes.js +146 -0
- package/resources/mailboxes/mailboxes.js.map +1 -0
- package/resources/mailboxes/mailboxes.mjs +141 -0
- package/resources/mailboxes/mailboxes.mjs.map +1 -0
- package/resources/mailboxes/messages.d.mts +82 -0
- package/resources/mailboxes/messages.d.mts.map +1 -0
- package/resources/mailboxes/messages.d.ts +82 -0
- package/resources/mailboxes/messages.d.ts.map +1 -0
- package/resources/mailboxes/messages.js +39 -0
- package/resources/mailboxes/messages.js.map +1 -0
- package/resources/mailboxes/messages.mjs +35 -0
- package/resources/mailboxes/messages.mjs.map +1 -0
- package/resources/mailboxes.d.mts +2 -0
- package/resources/mailboxes.d.mts.map +1 -0
- package/resources/mailboxes.d.ts +2 -0
- package/resources/mailboxes.d.ts.map +1 -0
- package/resources/mailboxes.js +6 -0
- package/resources/mailboxes.js.map +1 -0
- package/resources/mailboxes.mjs +3 -0
- package/resources/mailboxes.mjs.map +1 -0
- package/src/client.ts +37 -0
- package/src/resources/index.ts +17 -0
- package/src/resources/mailboxes/index.ts +26 -0
- package/src/resources/mailboxes/mailboxes.ts +618 -0
- package/src/resources/mailboxes/messages.ts +134 -0
- package/src/resources/mailboxes.ts +3 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../../core/resource';
|
|
4
|
+
import { APIPromise } from '../../core/api-promise';
|
|
5
|
+
import { RequestOptions } from '../../internal/request-options';
|
|
6
|
+
import { path } from '../../internal/utils/path';
|
|
7
|
+
|
|
8
|
+
export class Messages extends APIResource {
|
|
9
|
+
/**
|
|
10
|
+
* Get a mailbox message
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* ```ts
|
|
14
|
+
* const message = await client.mailboxes.messages.retrieve(
|
|
15
|
+
* 'x',
|
|
16
|
+
* { mailboxId: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e' },
|
|
17
|
+
* );
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
retrieve(
|
|
21
|
+
messageID: string,
|
|
22
|
+
params: MessageRetrieveParams,
|
|
23
|
+
options?: RequestOptions,
|
|
24
|
+
): APIPromise<MessageRetrieveResponse> {
|
|
25
|
+
const { mailboxId } = params;
|
|
26
|
+
return this._client.get(path`/mailboxes/${mailboxId}/messages/${messageID}`, options);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* Lists messages for a mailbox with keyset pagination and time/sender/hasOtp
|
|
31
|
+
* filters for polling.
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```ts
|
|
35
|
+
* const messages = await client.mailboxes.messages.list(
|
|
36
|
+
* '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
|
|
37
|
+
* );
|
|
38
|
+
* ```
|
|
39
|
+
*/
|
|
40
|
+
list(
|
|
41
|
+
mailboxID: string,
|
|
42
|
+
query: MessageListParams | null | undefined = {},
|
|
43
|
+
options?: RequestOptions,
|
|
44
|
+
): APIPromise<MessageListResponse> {
|
|
45
|
+
return this._client.get(path`/mailboxes/${mailboxID}/messages`, { query, ...options });
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export interface MessageRetrieveResponse {
|
|
50
|
+
data: MessageRetrieveResponse.Data;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export namespace MessageRetrieveResponse {
|
|
54
|
+
export interface Data {
|
|
55
|
+
id: string;
|
|
56
|
+
|
|
57
|
+
attachmentCount: number;
|
|
58
|
+
|
|
59
|
+
attachments: Array<Data.Attachment>;
|
|
60
|
+
|
|
61
|
+
fromAddress: string | null;
|
|
62
|
+
|
|
63
|
+
fromName: string | null;
|
|
64
|
+
|
|
65
|
+
hasOtp: boolean;
|
|
66
|
+
|
|
67
|
+
mailboxId: string;
|
|
68
|
+
|
|
69
|
+
receivedAt: string;
|
|
70
|
+
|
|
71
|
+
subject: string | null;
|
|
72
|
+
|
|
73
|
+
textBody: string | null;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export namespace Data {
|
|
77
|
+
export interface Attachment {
|
|
78
|
+
contentType: string | null;
|
|
79
|
+
|
|
80
|
+
name: string | null;
|
|
81
|
+
|
|
82
|
+
size: number;
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
export interface MessageListResponse {
|
|
88
|
+
items: Array<MessageListResponse.Item>;
|
|
89
|
+
|
|
90
|
+
nextCursor: string | null;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
export namespace MessageListResponse {
|
|
94
|
+
export interface Item {
|
|
95
|
+
id: string;
|
|
96
|
+
|
|
97
|
+
fromAddress: string | null;
|
|
98
|
+
|
|
99
|
+
hasOtp: boolean;
|
|
100
|
+
|
|
101
|
+
mailboxId: string;
|
|
102
|
+
|
|
103
|
+
preview: string | null;
|
|
104
|
+
|
|
105
|
+
receivedAt: string;
|
|
106
|
+
|
|
107
|
+
subject: string | null;
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
export interface MessageRetrieveParams {
|
|
112
|
+
mailboxId: string;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
export interface MessageListParams {
|
|
116
|
+
after?: string;
|
|
117
|
+
|
|
118
|
+
cursor?: string;
|
|
119
|
+
|
|
120
|
+
hasOtp?: 'true' | 'false';
|
|
121
|
+
|
|
122
|
+
limit?: number;
|
|
123
|
+
|
|
124
|
+
sender?: string;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
export declare namespace Messages {
|
|
128
|
+
export {
|
|
129
|
+
type MessageRetrieveResponse as MessageRetrieveResponse,
|
|
130
|
+
type MessageListResponse as MessageListResponse,
|
|
131
|
+
type MessageRetrieveParams as MessageRetrieveParams,
|
|
132
|
+
type MessageListParams as MessageListParams,
|
|
133
|
+
};
|
|
134
|
+
}
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '5.
|
|
1
|
+
export const VERSION = '5.4.0'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "5.
|
|
1
|
+
export declare const VERSION = "5.4.0";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "5.
|
|
1
|
+
export declare const VERSION = "5.4.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '5.
|
|
1
|
+
export const VERSION = '5.4.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|