agentmail 0.5.3 → 0.5.5
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/cjs/BaseClient.js +2 -2
- package/dist/cjs/api/resources/agent/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/agent/client/Client.js +1 -1
- package/dist/cjs/api/resources/inboxes/client/Client.d.ts +2 -3
- package/dist/cjs/api/resources/inboxes/client/Client.js +10 -3
- package/dist/cjs/api/resources/inboxes/types/CreateInboxRequest.d.ts +2 -0
- package/dist/cjs/api/resources/inboxes/types/Inbox.d.ts +2 -0
- package/dist/cjs/api/resources/inboxes/types/Metadata.d.ts +7 -0
- package/dist/cjs/api/resources/inboxes/types/Metadata.js +3 -0
- package/dist/cjs/api/resources/inboxes/types/MetadataValue.d.ts +4 -0
- package/dist/cjs/api/resources/inboxes/types/MetadataValue.js +3 -0
- package/dist/cjs/api/resources/inboxes/types/UpdateInboxRequest.d.ts +8 -1
- package/dist/cjs/api/resources/inboxes/types/UpdateMetadata.d.ts +8 -0
- package/dist/cjs/api/resources/inboxes/types/UpdateMetadata.js +3 -0
- package/dist/cjs/api/resources/inboxes/types/index.d.ts +3 -0
- package/dist/cjs/api/resources/inboxes/types/index.js +3 -0
- package/dist/cjs/api/resources/pods/resources/inboxes/client/Client.d.ts +1 -3
- package/dist/cjs/api/resources/pods/resources/inboxes/client/Client.js +1 -3
- package/dist/cjs/serialization/resources/inboxes/types/CreateInboxRequest.d.ts +2 -0
- package/dist/cjs/serialization/resources/inboxes/types/CreateInboxRequest.js +2 -0
- package/dist/cjs/serialization/resources/inboxes/types/Inbox.d.ts +2 -0
- package/dist/cjs/serialization/resources/inboxes/types/Inbox.js +2 -0
- package/dist/cjs/serialization/resources/inboxes/types/Metadata.d.ts +8 -0
- package/dist/cjs/serialization/resources/inboxes/types/Metadata.js +40 -0
- package/dist/cjs/serialization/resources/inboxes/types/MetadataValue.d.ts +7 -0
- package/dist/cjs/serialization/resources/inboxes/types/MetadataValue.js +43 -0
- package/dist/cjs/serialization/resources/inboxes/types/UpdateInboxRequest.d.ts +3 -1
- package/dist/cjs/serialization/resources/inboxes/types/UpdateInboxRequest.js +3 -1
- package/dist/cjs/serialization/resources/inboxes/types/UpdateMetadata.d.ts +8 -0
- package/dist/cjs/serialization/resources/inboxes/types/UpdateMetadata.js +40 -0
- package/dist/cjs/serialization/resources/inboxes/types/index.d.ts +3 -0
- package/dist/cjs/serialization/resources/inboxes/types/index.js +3 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.mjs +2 -2
- package/dist/esm/api/resources/agent/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/agent/client/Client.mjs +1 -1
- package/dist/esm/api/resources/inboxes/client/Client.d.mts +2 -3
- package/dist/esm/api/resources/inboxes/client/Client.mjs +10 -3
- package/dist/esm/api/resources/inboxes/types/CreateInboxRequest.d.mts +2 -0
- package/dist/esm/api/resources/inboxes/types/Inbox.d.mts +2 -0
- package/dist/esm/api/resources/inboxes/types/Metadata.d.mts +7 -0
- package/dist/esm/api/resources/inboxes/types/Metadata.mjs +2 -0
- package/dist/esm/api/resources/inboxes/types/MetadataValue.d.mts +4 -0
- package/dist/esm/api/resources/inboxes/types/MetadataValue.mjs +2 -0
- package/dist/esm/api/resources/inboxes/types/UpdateInboxRequest.d.mts +8 -1
- package/dist/esm/api/resources/inboxes/types/UpdateMetadata.d.mts +8 -0
- package/dist/esm/api/resources/inboxes/types/UpdateMetadata.mjs +2 -0
- package/dist/esm/api/resources/inboxes/types/index.d.mts +3 -0
- package/dist/esm/api/resources/inboxes/types/index.mjs +3 -0
- package/dist/esm/api/resources/pods/resources/inboxes/client/Client.d.mts +1 -3
- package/dist/esm/api/resources/pods/resources/inboxes/client/Client.mjs +1 -3
- package/dist/esm/serialization/resources/inboxes/types/CreateInboxRequest.d.mts +2 -0
- package/dist/esm/serialization/resources/inboxes/types/CreateInboxRequest.mjs +2 -0
- package/dist/esm/serialization/resources/inboxes/types/Inbox.d.mts +2 -0
- package/dist/esm/serialization/resources/inboxes/types/Inbox.mjs +2 -0
- package/dist/esm/serialization/resources/inboxes/types/Metadata.d.mts +8 -0
- package/dist/esm/serialization/resources/inboxes/types/Metadata.mjs +4 -0
- package/dist/esm/serialization/resources/inboxes/types/MetadataValue.d.mts +7 -0
- package/dist/esm/serialization/resources/inboxes/types/MetadataValue.mjs +7 -0
- package/dist/esm/serialization/resources/inboxes/types/UpdateInboxRequest.d.mts +3 -1
- package/dist/esm/serialization/resources/inboxes/types/UpdateInboxRequest.mjs +3 -1
- package/dist/esm/serialization/resources/inboxes/types/UpdateMetadata.d.mts +8 -0
- package/dist/esm/serialization/resources/inboxes/types/UpdateMetadata.mjs +4 -0
- package/dist/esm/serialization/resources/inboxes/types/index.d.mts +3 -0
- package/dist/esm/serialization/resources/inboxes/types/index.mjs +3 -0
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/dist/llms-full.txt +373 -58
- package/dist/llms.txt +184 -184
- package/package.json +1 -1
- package/reference.md +3 -7
package/dist/llms-full.txt
CHANGED
|
@@ -538,6 +538,89 @@ don't provide them, AgentMail will generate a unique address for you using our
|
|
|
538
538
|
default domain. Check out our [guide on managing
|
|
539
539
|
domains](/guides/domains/managing-domains) to learn more.
|
|
540
540
|
|
|
541
|
+
## Metadata
|
|
542
|
+
|
|
543
|
+
Attach your own key-value data to any `Inbox` with the `metadata` field. Use it to link an inbox to records in your own system: a user ID, an agent name, or feature flags. Metadata is returned on every inbox response.
|
|
544
|
+
|
|
545
|
+
Values may be a string, number, or boolean. An `Inbox` can hold up to 256 keys, and each key and string value is limited to 256 characters.
|
|
546
|
+
|
|
547
|
+
```python title="Python"
|
|
548
|
+
# Attach metadata when creating an inbox; values may be a string, int, float, or boolean
|
|
549
|
+
inbox = client.inboxes.create(
|
|
550
|
+
username="support-agent",
|
|
551
|
+
metadata={
|
|
552
|
+
"tenant_id": "acme", # string
|
|
553
|
+
"seat_count": 5, # int
|
|
554
|
+
"monthly_spend": 19.99, # float
|
|
555
|
+
"active": True, # boolean
|
|
556
|
+
},
|
|
557
|
+
)
|
|
558
|
+
|
|
559
|
+
# Read it back from any inbox response
|
|
560
|
+
print(inbox.metadata)
|
|
561
|
+
```
|
|
562
|
+
|
|
563
|
+
```typescript title="TypeScript"
|
|
564
|
+
// Attach metadata when creating an inbox; values may be a string, int, float, or boolean
|
|
565
|
+
const inbox = await client.inboxes.create({
|
|
566
|
+
username: "support-agent",
|
|
567
|
+
metadata: {
|
|
568
|
+
tenant_id: "acme", // string
|
|
569
|
+
seat_count: 5, // int
|
|
570
|
+
monthly_spend: 19.99, // float
|
|
571
|
+
active: true, // boolean
|
|
572
|
+
},
|
|
573
|
+
});
|
|
574
|
+
|
|
575
|
+
// Read it back from any inbox response
|
|
576
|
+
console.log(inbox.metadata);
|
|
577
|
+
```
|
|
578
|
+
|
|
579
|
+
### Updating metadata
|
|
580
|
+
|
|
581
|
+
Updates **merge** into the inbox's existing metadata — keys you include are added or overwritten, and keys you omit are preserved.
|
|
582
|
+
|
|
583
|
+
To remove a single key, send it with a `null` value. To clear all metadata at
|
|
584
|
+
once, send `metadata` as `null`. Every update must include either
|
|
585
|
+
`display_name` or `metadata`.
|
|
586
|
+
|
|
587
|
+
```python title="Python"
|
|
588
|
+
# Add or overwrite keys; the keys you omit stay unchanged
|
|
589
|
+
client.inboxes.update(
|
|
590
|
+
inbox_id="support-agent@agentmail.to",
|
|
591
|
+
metadata={"tier": "enterprise"},
|
|
592
|
+
)
|
|
593
|
+
|
|
594
|
+
# Remove a single key
|
|
595
|
+
client.inboxes.update(
|
|
596
|
+
inbox_id="support-agent@agentmail.to",
|
|
597
|
+
metadata={"tier": None},
|
|
598
|
+
)
|
|
599
|
+
|
|
600
|
+
# Clear all metadata
|
|
601
|
+
client.inboxes.update(
|
|
602
|
+
inbox_id="support-agent@agentmail.to",
|
|
603
|
+
metadata=None,
|
|
604
|
+
)
|
|
605
|
+
```
|
|
606
|
+
|
|
607
|
+
```typescript title="TypeScript"
|
|
608
|
+
// Add or overwrite keys; the keys you omit stay unchanged
|
|
609
|
+
await client.inboxes.update("support-agent@agentmail.to", {
|
|
610
|
+
metadata: { tier: "enterprise" },
|
|
611
|
+
});
|
|
612
|
+
|
|
613
|
+
// Remove a single key
|
|
614
|
+
await client.inboxes.update("support-agent@agentmail.to", {
|
|
615
|
+
metadata: { tier: null },
|
|
616
|
+
});
|
|
617
|
+
|
|
618
|
+
// Clear all metadata
|
|
619
|
+
await client.inboxes.update("support-agent@agentmail.to", {
|
|
620
|
+
metadata: null,
|
|
621
|
+
});
|
|
622
|
+
```
|
|
623
|
+
|
|
541
624
|
## Inbox-scoped API keys
|
|
542
625
|
|
|
543
626
|
You can create API keys that are restricted to a single inbox. An inbox-scoped key can only access that inbox's threads, messages, and drafts. This is useful when you want to give an agent or integration the minimum access it needs.
|
|
@@ -575,10 +658,10 @@ AgentMail Inboxes — copy into Cursor/Claude.
|
|
|
575
658
|
Setup: pip install agentmail python-dotenv. Set AGENTMAIL_API_KEY in .env.
|
|
576
659
|
|
|
577
660
|
API reference:
|
|
578
|
-
- inboxes.create(username?, domain?, display_name?, client_id?) — client_id for idempotent retries
|
|
661
|
+
- inboxes.create(username?, domain?, display_name?, client_id?, metadata?) — client_id for idempotent retries; metadata is custom key-value data
|
|
579
662
|
- inboxes.get(inbox_id)
|
|
580
663
|
- inboxes.list(limit?, page_token?)
|
|
581
|
-
- inboxes.update(inbox_id, display_name)
|
|
664
|
+
- inboxes.update(inbox_id, display_name?, metadata?) — at least one field required; metadata is merged, not replaced
|
|
582
665
|
- inboxes.delete(inbox_id)
|
|
583
666
|
- inboxes.api_keys.create(inbox_id, name) — inbox-scoped key
|
|
584
667
|
- inboxes.api_keys.list(inbox_id)
|
|
@@ -609,10 +692,10 @@ print(f"Total: {all_inboxes.count}")
|
|
|
609
692
|
* Setup: npm install agentmail dotenv. Set AGENTMAIL_API_KEY in .env.
|
|
610
693
|
*
|
|
611
694
|
* API reference:
|
|
612
|
-
* - inboxes.create({ username?, domain?, displayName?, clientId? })
|
|
695
|
+
* - inboxes.create({ username?, domain?, displayName?, clientId?, metadata? }) — metadata is custom key-value data
|
|
613
696
|
* - inboxes.get(inboxId)
|
|
614
697
|
* - inboxes.list({ limit?, pageToken? })
|
|
615
|
-
* - inboxes.update(inboxId, { displayName })
|
|
698
|
+
* - inboxes.update(inboxId, { displayName?, metadata? }) — at least one field required
|
|
616
699
|
* - inboxes.delete(inboxId)
|
|
617
700
|
* - inboxes.apiKeys.create(inboxId, { name }) — inbox-scoped key
|
|
618
701
|
* - inboxes.apiKeys.list(inboxId)
|
|
@@ -5157,8 +5240,6 @@ For more details on scheduled sending—including how to cancel, reschedule, lis
|
|
|
5157
5240
|
|
|
5158
5241
|
> Configure IMAP and SMTP to access your AgentMail inboxes using email clients or programmatic access.
|
|
5159
5242
|
|
|
5160
|
-
IMAP support is currently under development and will be available in the coming weeks. The documentation below describes the planned functionality. SMTP is fully available today.
|
|
5161
|
-
|
|
5162
5243
|
AgentMail supports standard IMAP and SMTP protocols, allowing you to connect using traditional email clients or integrate with existing systems that rely on these protocols.
|
|
5163
5244
|
|
|
5164
5245
|
## What are IMAP and SMTP?
|
|
@@ -5202,9 +5283,15 @@ be rejected. Make sure to enable SSL/TLS in your email client settings.
|
|
|
5202
5283
|
| **Password** | Your API key |
|
|
5203
5284
|
| **SSL/TLS** | **Required** (must be enabled) |
|
|
5204
5285
|
|
|
5205
|
-
|
|
5206
|
-
|
|
5207
|
-
API](/introduction)
|
|
5286
|
+
IMAP exposes the following folders: **INBOX**, **Sent**, **Trash**, and
|
|
5287
|
+
**Spam**. A **Drafts** folder is also listed for client compatibility but
|
|
5288
|
+
always appears empty — use the [AgentMail API](/introduction) to create
|
|
5289
|
+
and manage drafts.
|
|
5290
|
+
|
|
5291
|
+
The IMAP server supports the `IDLE` extension (RFC 2177), so modern
|
|
5292
|
+
clients (Thunderbird, Outlook, Apple Mail) receive new messages
|
|
5293
|
+
push-style without polling. Clients negotiate `IDLE` automatically when
|
|
5294
|
+
supported — no extra configuration needed.
|
|
5208
5295
|
|
|
5209
5296
|
### Python IMAP Example
|
|
5210
5297
|
|
|
@@ -5224,7 +5311,7 @@ try:
|
|
|
5224
5311
|
# Authenticate using inbox email as username
|
|
5225
5312
|
imap.login(inbox_email, api_key)
|
|
5226
5313
|
|
|
5227
|
-
# Select
|
|
5314
|
+
# Select a folder (INBOX, Sent, Trash, or Spam)
|
|
5228
5315
|
imap.select("INBOX")
|
|
5229
5316
|
|
|
5230
5317
|
# Search for all messages
|
|
@@ -5278,16 +5365,18 @@ imap.connect();
|
|
|
5278
5365
|
|
|
5279
5366
|
Use SMTP to send emails from your AgentMail inbox.
|
|
5280
5367
|
|
|
5281
|
-
|
|
5282
|
-
|
|
5368
|
+
Encryption is **required** for all SMTP connections. Connect using **port 465
|
|
5369
|
+
with implicit TLS** (SSL on connect) or **port 587 with STARTTLS** (upgrade
|
|
5370
|
+
in-band). On port 587, attempting to authenticate before issuing `STARTTLS`
|
|
5371
|
+
is rejected with a `538` error.
|
|
5283
5372
|
|
|
5284
|
-
| Setting
|
|
5285
|
-
|
|
|
5286
|
-
| **Host**
|
|
5287
|
-
| **Port**
|
|
5288
|
-
| **Username**
|
|
5289
|
-
| **Password**
|
|
5290
|
-
| **SSL/TLS
|
|
5373
|
+
| Setting | Value |
|
|
5374
|
+
| -------------- | ----------------------------------------------------- |
|
|
5375
|
+
| **Host** | `smtp.agentmail.to` |
|
|
5376
|
+
| **Port** | `465` (implicit TLS) or `587` (STARTTLS) |
|
|
5377
|
+
| **Username** | Your inbox email (e.g., `myinbox@agentmail.to`) |
|
|
5378
|
+
| **Password** | Your API key |
|
|
5379
|
+
| **Encryption** | Port `465`: SSL/TLS on connect · Port `587`: STARTTLS |
|
|
5291
5380
|
|
|
5292
5381
|
The "From" address in your email should match the email address of your inbox
|
|
5293
5382
|
(e.g., `myinbox@agentmail.to`). Using a different From address may result in
|
|
@@ -5318,11 +5407,17 @@ msg["From"] = inbox_email # Use your inbox email as the From address
|
|
|
5318
5407
|
msg["To"] = "recipient@example.com"
|
|
5319
5408
|
msg.attach(MIMEText("This is a test email sent via SMTP.", "plain"))
|
|
5320
5409
|
|
|
5321
|
-
# Connect with
|
|
5410
|
+
# Connect with implicit TLS on port 465 and send
|
|
5322
5411
|
with smtplib.SMTP_SSL("smtp.agentmail.to", 465) as server:
|
|
5323
5412
|
server.login(inbox_email, api_key)
|
|
5324
5413
|
server.send_message(msg)
|
|
5325
5414
|
print("Email sent successfully!")
|
|
5415
|
+
|
|
5416
|
+
# Alternatively, use STARTTLS on port 587:
|
|
5417
|
+
# with smtplib.SMTP("smtp.agentmail.to", 587) as server:
|
|
5418
|
+
# server.starttls()
|
|
5419
|
+
# server.login(inbox_email, api_key)
|
|
5420
|
+
# server.send_message(msg)
|
|
5326
5421
|
```
|
|
5327
5422
|
|
|
5328
5423
|
### TypeScript SMTP Example
|
|
@@ -5337,7 +5432,8 @@ const apiKey = process.env.AGENTMAIL_API_KEY!; // From Dashboard → API Keys
|
|
|
5337
5432
|
const transporter = nodemailer.createTransport({
|
|
5338
5433
|
host: "smtp.agentmail.to",
|
|
5339
5434
|
port: 465,
|
|
5340
|
-
secure: true, //
|
|
5435
|
+
secure: true, // implicit TLS on port 465
|
|
5436
|
+
// For STARTTLS on port 587 instead, use: port: 587, secure: false
|
|
5341
5437
|
auth: {
|
|
5342
5438
|
user: inboxEmail,
|
|
5343
5439
|
pass: apiKey,
|
|
@@ -5359,13 +5455,14 @@ sendEmail().catch(console.error);
|
|
|
5359
5455
|
|
|
5360
5456
|
## Troubleshooting
|
|
5361
5457
|
|
|
5362
|
-
| Error
|
|
5363
|
-
|
|
|
5364
|
-
| "Authentication failed"
|
|
5365
|
-
| "Connection refused"
|
|
5366
|
-
| "
|
|
5367
|
-
| "
|
|
5368
|
-
| "
|
|
5458
|
+
| Error | Cause | Solution |
|
|
5459
|
+
| ------------------------------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
5460
|
+
| "Authentication failed" | Invalid credentials | Verify your inbox email and API key from the console |
|
|
5461
|
+
| "Connection refused" / handshake error | Wrong encryption mode for the port | Use SSL/TLS on connect for port `465`, or STARTTLS for port `587` |
|
|
5462
|
+
| `538` "Must issue a STARTTLS command first" | Plaintext AUTH on port `587` | Enable STARTTLS on port `587` (or use implicit TLS on `465`) before authenticating |
|
|
5463
|
+
| "Connection timeout" | Firewall blocking ports | Ensure ports 993 (IMAP) and 465/587 (SMTP) are open |
|
|
5464
|
+
| "Sender not authorized" | Wrong From address | Use your inbox's email address as the From address |
|
|
5465
|
+
| "Folder not found" | Folder name typo or unsupported folder | IMAP exposes `INBOX`, `Sent`, `Trash`, and `Spam`. Folder names other than `INBOX` are case-sensitive. Use the [API](/introduction) to manage drafts. |
|
|
5369
5466
|
|
|
5370
5467
|
## When to Use IMAP/SMTP vs API
|
|
5371
5468
|
|
|
@@ -11984,7 +12081,7 @@ Verify an agent organization using the 6-digit OTP sent to the human's email dur
|
|
|
11984
12081
|
|
|
11985
12082
|
On success, the organization is upgraded from `agent_unverified` to `agent_verified`, the send allowlist is removed, and free plan entitlements are applied.
|
|
11986
12083
|
|
|
11987
|
-
The OTP expires after 24 hours and allows a maximum of 10 attempts.
|
|
12084
|
+
The OTP expires after 24 hours and allows a maximum of 10 attempts. If you run into any difficulties receiving the OTP code, you can also create an account on [console.agentmail.to](https://console.agentmail.to) using the human email address you provided to verify your account.
|
|
11988
12085
|
|
|
11989
12086
|
**CLI:**
|
|
11990
12087
|
```bash
|
|
@@ -12015,7 +12112,11 @@ paths:
|
|
|
12015
12112
|
entitlements are applied.
|
|
12016
12113
|
|
|
12017
12114
|
|
|
12018
|
-
The OTP expires after 24 hours and allows a maximum of 10 attempts.
|
|
12115
|
+
The OTP expires after 24 hours and allows a maximum of 10 attempts. If
|
|
12116
|
+
you run into any difficulties receiving the OTP code, you can also
|
|
12117
|
+
create an account on
|
|
12118
|
+
[console.agentmail.to](https://console.agentmail.to) using the human
|
|
12119
|
+
email address you provided to verify your account.
|
|
12019
12120
|
|
|
12020
12121
|
|
|
12021
12122
|
**CLI:**
|
|
@@ -12334,6 +12435,22 @@ components:
|
|
|
12334
12435
|
type: string
|
|
12335
12436
|
description: Client ID of inbox.
|
|
12336
12437
|
title: ClientId
|
|
12438
|
+
type_inboxes:MetadataValue:
|
|
12439
|
+
oneOf:
|
|
12440
|
+
- type: string
|
|
12441
|
+
- type: number
|
|
12442
|
+
format: double
|
|
12443
|
+
- type: boolean
|
|
12444
|
+
description: A metadata value. May be a string, number, or boolean.
|
|
12445
|
+
title: MetadataValue
|
|
12446
|
+
type_inboxes:Metadata:
|
|
12447
|
+
type: object
|
|
12448
|
+
additionalProperties:
|
|
12449
|
+
$ref: '#/components/schemas/type_inboxes:MetadataValue'
|
|
12450
|
+
description: |-
|
|
12451
|
+
Custom key-value pairs attached to the inbox. Up to 256 keys. Keys and
|
|
12452
|
+
string values are each limited to 256 characters.
|
|
12453
|
+
title: Metadata
|
|
12337
12454
|
type_inboxes:Inbox:
|
|
12338
12455
|
type: object
|
|
12339
12456
|
properties:
|
|
@@ -12347,6 +12464,9 @@ components:
|
|
|
12347
12464
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
12348
12465
|
client_id:
|
|
12349
12466
|
$ref: '#/components/schemas/type_inboxes:ClientId'
|
|
12467
|
+
metadata:
|
|
12468
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
12469
|
+
description: Custom metadata attached to the inbox.
|
|
12350
12470
|
updated_at:
|
|
12351
12471
|
type: string
|
|
12352
12472
|
format: date-time
|
|
@@ -12596,6 +12716,22 @@ components:
|
|
|
12596
12716
|
type: string
|
|
12597
12717
|
description: Client ID of inbox.
|
|
12598
12718
|
title: ClientId
|
|
12719
|
+
type_inboxes:MetadataValue:
|
|
12720
|
+
oneOf:
|
|
12721
|
+
- type: string
|
|
12722
|
+
- type: number
|
|
12723
|
+
format: double
|
|
12724
|
+
- type: boolean
|
|
12725
|
+
description: A metadata value. May be a string, number, or boolean.
|
|
12726
|
+
title: MetadataValue
|
|
12727
|
+
type_inboxes:Metadata:
|
|
12728
|
+
type: object
|
|
12729
|
+
additionalProperties:
|
|
12730
|
+
$ref: '#/components/schemas/type_inboxes:MetadataValue'
|
|
12731
|
+
description: |-
|
|
12732
|
+
Custom key-value pairs attached to the inbox. Up to 256 keys. Keys and
|
|
12733
|
+
string values are each limited to 256 characters.
|
|
12734
|
+
title: Metadata
|
|
12599
12735
|
type_inboxes:Inbox:
|
|
12600
12736
|
type: object
|
|
12601
12737
|
properties:
|
|
@@ -12609,6 +12745,9 @@ components:
|
|
|
12609
12745
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
12610
12746
|
client_id:
|
|
12611
12747
|
$ref: '#/components/schemas/type_inboxes:ClientId'
|
|
12748
|
+
metadata:
|
|
12749
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
12750
|
+
description: Custom metadata attached to the inbox.
|
|
12612
12751
|
updated_at:
|
|
12613
12752
|
type: string
|
|
12614
12753
|
format: date-time
|
|
@@ -12854,6 +12993,22 @@ components:
|
|
|
12854
12993
|
type: string
|
|
12855
12994
|
description: Client ID of inbox.
|
|
12856
12995
|
title: ClientId
|
|
12996
|
+
type_inboxes:MetadataValue:
|
|
12997
|
+
oneOf:
|
|
12998
|
+
- type: string
|
|
12999
|
+
- type: number
|
|
13000
|
+
format: double
|
|
13001
|
+
- type: boolean
|
|
13002
|
+
description: A metadata value. May be a string, number, or boolean.
|
|
13003
|
+
title: MetadataValue
|
|
13004
|
+
type_inboxes:Metadata:
|
|
13005
|
+
type: object
|
|
13006
|
+
additionalProperties:
|
|
13007
|
+
$ref: '#/components/schemas/type_inboxes:MetadataValue'
|
|
13008
|
+
description: |-
|
|
13009
|
+
Custom key-value pairs attached to the inbox. Up to 256 keys. Keys and
|
|
13010
|
+
string values are each limited to 256 characters.
|
|
13011
|
+
title: Metadata
|
|
12857
13012
|
type_inboxes:CreateInboxRequest:
|
|
12858
13013
|
type: object
|
|
12859
13014
|
properties:
|
|
@@ -12869,6 +13024,9 @@ components:
|
|
|
12869
13024
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
12870
13025
|
client_id:
|
|
12871
13026
|
$ref: '#/components/schemas/type_inboxes:ClientId'
|
|
13027
|
+
metadata:
|
|
13028
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
13029
|
+
description: Custom metadata to attach to the inbox.
|
|
12872
13030
|
title: CreateInboxRequest
|
|
12873
13031
|
type_pods:PodId:
|
|
12874
13032
|
type: string
|
|
@@ -12895,6 +13053,9 @@ components:
|
|
|
12895
13053
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
12896
13054
|
client_id:
|
|
12897
13055
|
$ref: '#/components/schemas/type_inboxes:ClientId'
|
|
13056
|
+
metadata:
|
|
13057
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
13058
|
+
description: Custom metadata attached to the inbox.
|
|
12898
13059
|
updated_at:
|
|
12899
13060
|
type: string
|
|
12900
13061
|
format: date-time
|
|
@@ -13121,6 +13282,12 @@ paths:
|
|
|
13121
13282
|
application/json:
|
|
13122
13283
|
schema:
|
|
13123
13284
|
$ref: '#/components/schemas/type_inboxes:Inbox'
|
|
13285
|
+
'400':
|
|
13286
|
+
description: Error response with status 400
|
|
13287
|
+
content:
|
|
13288
|
+
application/json:
|
|
13289
|
+
schema:
|
|
13290
|
+
$ref: '#/components/schemas/type_:ValidationErrorResponse'
|
|
13124
13291
|
'404':
|
|
13125
13292
|
description: Error response with status 404
|
|
13126
13293
|
content:
|
|
@@ -13147,13 +13314,40 @@ components:
|
|
|
13147
13314
|
type: string
|
|
13148
13315
|
description: 'Display name: `Display Name <username@domain.com>`.'
|
|
13149
13316
|
title: DisplayName
|
|
13317
|
+
type_inboxes:MetadataValue:
|
|
13318
|
+
oneOf:
|
|
13319
|
+
- type: string
|
|
13320
|
+
- type: number
|
|
13321
|
+
format: double
|
|
13322
|
+
- type: boolean
|
|
13323
|
+
description: A metadata value. May be a string, number, or boolean.
|
|
13324
|
+
title: MetadataValue
|
|
13325
|
+
type_inboxes:Metadata:
|
|
13326
|
+
type: object
|
|
13327
|
+
additionalProperties:
|
|
13328
|
+
$ref: '#/components/schemas/type_inboxes:MetadataValue'
|
|
13329
|
+
description: |-
|
|
13330
|
+
Custom key-value pairs attached to the inbox. Up to 256 keys. Keys and
|
|
13331
|
+
string values are each limited to 256 characters.
|
|
13332
|
+
title: Metadata
|
|
13150
13333
|
type_inboxes:UpdateInboxRequest:
|
|
13151
13334
|
type: object
|
|
13152
13335
|
properties:
|
|
13153
13336
|
display_name:
|
|
13154
13337
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
13155
|
-
|
|
13156
|
-
|
|
13338
|
+
metadata:
|
|
13339
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
13340
|
+
description: >-
|
|
13341
|
+
Metadata to merge into the inbox's existing metadata. Keys you
|
|
13342
|
+
include
|
|
13343
|
+
|
|
13344
|
+
are added or overwritten; keys you omit are left unchanged. To
|
|
13345
|
+
remove a
|
|
13346
|
+
|
|
13347
|
+
single key, send it with a null value. To clear all metadata, send
|
|
13348
|
+
|
|
13349
|
+
`metadata` as null. Provide at least one of `display_name` or
|
|
13350
|
+
`metadata`.
|
|
13157
13351
|
title: UpdateInboxRequest
|
|
13158
13352
|
type_pods:PodId:
|
|
13159
13353
|
type: string
|
|
@@ -13180,6 +13374,9 @@ components:
|
|
|
13180
13374
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
13181
13375
|
client_id:
|
|
13182
13376
|
$ref: '#/components/schemas/type_inboxes:ClientId'
|
|
13377
|
+
metadata:
|
|
13378
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
13379
|
+
description: Custom metadata attached to the inbox.
|
|
13183
13380
|
updated_at:
|
|
13184
13381
|
type: string
|
|
13185
13382
|
format: date-time
|
|
@@ -13214,6 +13411,17 @@ components:
|
|
|
13214
13411
|
- name
|
|
13215
13412
|
- message
|
|
13216
13413
|
title: ErrorResponse
|
|
13414
|
+
type_:ValidationErrorResponse:
|
|
13415
|
+
type: object
|
|
13416
|
+
properties:
|
|
13417
|
+
name:
|
|
13418
|
+
$ref: '#/components/schemas/type_:ErrorName'
|
|
13419
|
+
errors:
|
|
13420
|
+
description: Validation errors.
|
|
13421
|
+
required:
|
|
13422
|
+
- name
|
|
13423
|
+
- errors
|
|
13424
|
+
title: ValidationErrorResponse
|
|
13217
13425
|
securitySchemes:
|
|
13218
13426
|
Bearer:
|
|
13219
13427
|
type: http
|
|
@@ -13230,9 +13438,7 @@ async function main() {
|
|
|
13230
13438
|
const client = new AgentMailClient({
|
|
13231
13439
|
apiKey: "YOUR_TOKEN_HERE",
|
|
13232
13440
|
});
|
|
13233
|
-
await client.inboxes.update("inbox_id", {
|
|
13234
|
-
displayName: "display_name",
|
|
13235
|
-
});
|
|
13441
|
+
await client.inboxes.update("inbox_id", {});
|
|
13236
13442
|
}
|
|
13237
13443
|
main();
|
|
13238
13444
|
|
|
@@ -13247,7 +13453,6 @@ client = AgentMail(
|
|
|
13247
13453
|
|
|
13248
13454
|
client.inboxes.update(
|
|
13249
13455
|
inbox_id="inbox_id",
|
|
13250
|
-
display_name="display_name",
|
|
13251
13456
|
)
|
|
13252
13457
|
|
|
13253
13458
|
```
|
|
@@ -13266,7 +13471,7 @@ func main() {
|
|
|
13266
13471
|
|
|
13267
13472
|
url := "https://api.agentmail.to/v0/inboxes/inbox_id"
|
|
13268
13473
|
|
|
13269
|
-
payload := strings.NewReader("{
|
|
13474
|
+
payload := strings.NewReader("{}")
|
|
13270
13475
|
|
|
13271
13476
|
req, _ := http.NewRequest("PATCH", url, payload)
|
|
13272
13477
|
|
|
@@ -13296,7 +13501,7 @@ http.use_ssl = true
|
|
|
13296
13501
|
request = Net::HTTP::Patch.new(url)
|
|
13297
13502
|
request["Authorization"] = 'Bearer <api_key>'
|
|
13298
13503
|
request["Content-Type"] = 'application/json'
|
|
13299
|
-
request.body = "{
|
|
13504
|
+
request.body = "{}"
|
|
13300
13505
|
|
|
13301
13506
|
response = http.request(request)
|
|
13302
13507
|
puts response.read_body
|
|
@@ -13309,7 +13514,7 @@ import com.mashape.unirest.http.Unirest;
|
|
|
13309
13514
|
HttpResponse<String> response = Unirest.patch("https://api.agentmail.to/v0/inboxes/inbox_id")
|
|
13310
13515
|
.header("Authorization", "Bearer <api_key>")
|
|
13311
13516
|
.header("Content-Type", "application/json")
|
|
13312
|
-
.body("{
|
|
13517
|
+
.body("{}")
|
|
13313
13518
|
.asString();
|
|
13314
13519
|
```
|
|
13315
13520
|
|
|
@@ -13320,9 +13525,7 @@ require_once('vendor/autoload.php');
|
|
|
13320
13525
|
$client = new \GuzzleHttp\Client();
|
|
13321
13526
|
|
|
13322
13527
|
$response = $client->request('PATCH', 'https://api.agentmail.to/v0/inboxes/inbox_id', [
|
|
13323
|
-
'body' => '{
|
|
13324
|
-
"display_name": "display_name"
|
|
13325
|
-
}',
|
|
13528
|
+
'body' => '{}',
|
|
13326
13529
|
'headers' => [
|
|
13327
13530
|
'Authorization' => 'Bearer <api_key>',
|
|
13328
13531
|
'Content-Type' => 'application/json',
|
|
@@ -13339,7 +13542,7 @@ var client = new RestClient("https://api.agentmail.to/v0/inboxes/inbox_id");
|
|
|
13339
13542
|
var request = new RestRequest(Method.PATCH);
|
|
13340
13543
|
request.AddHeader("Authorization", "Bearer <api_key>");
|
|
13341
13544
|
request.AddHeader("Content-Type", "application/json");
|
|
13342
|
-
request.AddParameter("application/json", "{
|
|
13545
|
+
request.AddParameter("application/json", "{}", ParameterType.RequestBody);
|
|
13343
13546
|
IRestResponse response = client.Execute(request);
|
|
13344
13547
|
```
|
|
13345
13548
|
|
|
@@ -13350,7 +13553,7 @@ let headers = [
|
|
|
13350
13553
|
"Authorization": "Bearer <api_key>",
|
|
13351
13554
|
"Content-Type": "application/json"
|
|
13352
13555
|
]
|
|
13353
|
-
let parameters = [
|
|
13556
|
+
let parameters = [] as [String : Any]
|
|
13354
13557
|
|
|
13355
13558
|
let postData = JSONSerialization.data(withJSONObject: parameters, options: [])
|
|
13356
13559
|
|
|
@@ -22561,6 +22764,9 @@ components:
|
|
|
22561
22764
|
type: string
|
|
22562
22765
|
format: date-time
|
|
22563
22766
|
description: Time at which entry was created.
|
|
22767
|
+
read_only:
|
|
22768
|
+
type: boolean
|
|
22769
|
+
description: Whether the entry is read-only and cannot be deleted via the API.
|
|
22564
22770
|
pod_id:
|
|
22565
22771
|
type: string
|
|
22566
22772
|
description: ID of pod.
|
|
@@ -22865,6 +23071,9 @@ components:
|
|
|
22865
23071
|
type: string
|
|
22866
23072
|
format: date-time
|
|
22867
23073
|
description: Time at which entry was created.
|
|
23074
|
+
read_only:
|
|
23075
|
+
type: boolean
|
|
23076
|
+
description: Whether the entry is read-only and cannot be deleted via the API.
|
|
22868
23077
|
pod_id:
|
|
22869
23078
|
type: string
|
|
22870
23079
|
description: ID of pod.
|
|
@@ -23183,6 +23392,9 @@ components:
|
|
|
23183
23392
|
type: string
|
|
23184
23393
|
format: date-time
|
|
23185
23394
|
description: Time at which entry was created.
|
|
23395
|
+
read_only:
|
|
23396
|
+
type: boolean
|
|
23397
|
+
description: Whether the entry is read-only and cannot be deleted via the API.
|
|
23186
23398
|
pod_id:
|
|
23187
23399
|
type: string
|
|
23188
23400
|
description: ID of pod.
|
|
@@ -34327,6 +34539,9 @@ components:
|
|
|
34327
34539
|
type: string
|
|
34328
34540
|
format: date-time
|
|
34329
34541
|
description: Time at which entry was created.
|
|
34542
|
+
read_only:
|
|
34543
|
+
type: boolean
|
|
34544
|
+
description: Whether the entry is read-only and cannot be deleted via the API.
|
|
34330
34545
|
required:
|
|
34331
34546
|
- entry
|
|
34332
34547
|
- organization_id
|
|
@@ -34614,6 +34829,9 @@ components:
|
|
|
34614
34829
|
type: string
|
|
34615
34830
|
format: date-time
|
|
34616
34831
|
description: Time at which entry was created.
|
|
34832
|
+
read_only:
|
|
34833
|
+
type: boolean
|
|
34834
|
+
description: Whether the entry is read-only and cannot be deleted via the API.
|
|
34617
34835
|
required:
|
|
34618
34836
|
- entry
|
|
34619
34837
|
- organization_id
|
|
@@ -34915,6 +35133,9 @@ components:
|
|
|
34915
35133
|
type: string
|
|
34916
35134
|
format: date-time
|
|
34917
35135
|
description: Time at which entry was created.
|
|
35136
|
+
read_only:
|
|
35137
|
+
type: boolean
|
|
35138
|
+
description: Whether the entry is read-only and cannot be deleted via the API.
|
|
34918
35139
|
required:
|
|
34919
35140
|
- entry
|
|
34920
35141
|
- organization_id
|
|
@@ -37775,6 +37996,22 @@ components:
|
|
|
37775
37996
|
type: string
|
|
37776
37997
|
description: Client ID of inbox.
|
|
37777
37998
|
title: ClientId
|
|
37999
|
+
type_inboxes:MetadataValue:
|
|
38000
|
+
oneOf:
|
|
38001
|
+
- type: string
|
|
38002
|
+
- type: number
|
|
38003
|
+
format: double
|
|
38004
|
+
- type: boolean
|
|
38005
|
+
description: A metadata value. May be a string, number, or boolean.
|
|
38006
|
+
title: MetadataValue
|
|
38007
|
+
type_inboxes:Metadata:
|
|
38008
|
+
type: object
|
|
38009
|
+
additionalProperties:
|
|
38010
|
+
$ref: '#/components/schemas/type_inboxes:MetadataValue'
|
|
38011
|
+
description: |-
|
|
38012
|
+
Custom key-value pairs attached to the inbox. Up to 256 keys. Keys and
|
|
38013
|
+
string values are each limited to 256 characters.
|
|
38014
|
+
title: Metadata
|
|
37778
38015
|
type_inboxes:Inbox:
|
|
37779
38016
|
type: object
|
|
37780
38017
|
properties:
|
|
@@ -37788,6 +38025,9 @@ components:
|
|
|
37788
38025
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
37789
38026
|
client_id:
|
|
37790
38027
|
$ref: '#/components/schemas/type_inboxes:ClientId'
|
|
38028
|
+
metadata:
|
|
38029
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
38030
|
+
description: Custom metadata attached to the inbox.
|
|
37791
38031
|
updated_at:
|
|
37792
38032
|
type: string
|
|
37793
38033
|
format: date-time
|
|
@@ -38063,6 +38303,22 @@ components:
|
|
|
38063
38303
|
type: string
|
|
38064
38304
|
description: Client ID of inbox.
|
|
38065
38305
|
title: ClientId
|
|
38306
|
+
type_inboxes:MetadataValue:
|
|
38307
|
+
oneOf:
|
|
38308
|
+
- type: string
|
|
38309
|
+
- type: number
|
|
38310
|
+
format: double
|
|
38311
|
+
- type: boolean
|
|
38312
|
+
description: A metadata value. May be a string, number, or boolean.
|
|
38313
|
+
title: MetadataValue
|
|
38314
|
+
type_inboxes:Metadata:
|
|
38315
|
+
type: object
|
|
38316
|
+
additionalProperties:
|
|
38317
|
+
$ref: '#/components/schemas/type_inboxes:MetadataValue'
|
|
38318
|
+
description: |-
|
|
38319
|
+
Custom key-value pairs attached to the inbox. Up to 256 keys. Keys and
|
|
38320
|
+
string values are each limited to 256 characters.
|
|
38321
|
+
title: Metadata
|
|
38066
38322
|
type_inboxes:Inbox:
|
|
38067
38323
|
type: object
|
|
38068
38324
|
properties:
|
|
@@ -38076,6 +38332,9 @@ components:
|
|
|
38076
38332
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
38077
38333
|
client_id:
|
|
38078
38334
|
$ref: '#/components/schemas/type_inboxes:ClientId'
|
|
38335
|
+
metadata:
|
|
38336
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
38337
|
+
description: Custom metadata attached to the inbox.
|
|
38079
38338
|
updated_at:
|
|
38080
38339
|
type: string
|
|
38081
38340
|
format: date-time
|
|
@@ -38331,6 +38590,22 @@ components:
|
|
|
38331
38590
|
type: string
|
|
38332
38591
|
description: Client ID of inbox.
|
|
38333
38592
|
title: ClientId
|
|
38593
|
+
type_inboxes:MetadataValue:
|
|
38594
|
+
oneOf:
|
|
38595
|
+
- type: string
|
|
38596
|
+
- type: number
|
|
38597
|
+
format: double
|
|
38598
|
+
- type: boolean
|
|
38599
|
+
description: A metadata value. May be a string, number, or boolean.
|
|
38600
|
+
title: MetadataValue
|
|
38601
|
+
type_inboxes:Metadata:
|
|
38602
|
+
type: object
|
|
38603
|
+
additionalProperties:
|
|
38604
|
+
$ref: '#/components/schemas/type_inboxes:MetadataValue'
|
|
38605
|
+
description: |-
|
|
38606
|
+
Custom key-value pairs attached to the inbox. Up to 256 keys. Keys and
|
|
38607
|
+
string values are each limited to 256 characters.
|
|
38608
|
+
title: Metadata
|
|
38334
38609
|
type_inboxes:CreateInboxRequest:
|
|
38335
38610
|
type: object
|
|
38336
38611
|
properties:
|
|
@@ -38346,6 +38621,9 @@ components:
|
|
|
38346
38621
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
38347
38622
|
client_id:
|
|
38348
38623
|
$ref: '#/components/schemas/type_inboxes:ClientId'
|
|
38624
|
+
metadata:
|
|
38625
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
38626
|
+
description: Custom metadata to attach to the inbox.
|
|
38349
38627
|
title: CreateInboxRequest
|
|
38350
38628
|
type_inboxes:InboxId:
|
|
38351
38629
|
type: string
|
|
@@ -38368,6 +38646,9 @@ components:
|
|
|
38368
38646
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
38369
38647
|
client_id:
|
|
38370
38648
|
$ref: '#/components/schemas/type_inboxes:ClientId'
|
|
38649
|
+
metadata:
|
|
38650
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
38651
|
+
description: Custom metadata attached to the inbox.
|
|
38371
38652
|
updated_at:
|
|
38372
38653
|
type: string
|
|
38373
38654
|
format: date-time
|
|
@@ -38638,13 +38919,40 @@ components:
|
|
|
38638
38919
|
type: string
|
|
38639
38920
|
description: 'Display name: `Display Name <username@domain.com>`.'
|
|
38640
38921
|
title: DisplayName
|
|
38922
|
+
type_inboxes:MetadataValue:
|
|
38923
|
+
oneOf:
|
|
38924
|
+
- type: string
|
|
38925
|
+
- type: number
|
|
38926
|
+
format: double
|
|
38927
|
+
- type: boolean
|
|
38928
|
+
description: A metadata value. May be a string, number, or boolean.
|
|
38929
|
+
title: MetadataValue
|
|
38930
|
+
type_inboxes:Metadata:
|
|
38931
|
+
type: object
|
|
38932
|
+
additionalProperties:
|
|
38933
|
+
$ref: '#/components/schemas/type_inboxes:MetadataValue'
|
|
38934
|
+
description: |-
|
|
38935
|
+
Custom key-value pairs attached to the inbox. Up to 256 keys. Keys and
|
|
38936
|
+
string values are each limited to 256 characters.
|
|
38937
|
+
title: Metadata
|
|
38641
38938
|
type_inboxes:UpdateInboxRequest:
|
|
38642
38939
|
type: object
|
|
38643
38940
|
properties:
|
|
38644
38941
|
display_name:
|
|
38645
38942
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
38646
|
-
|
|
38647
|
-
|
|
38943
|
+
metadata:
|
|
38944
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
38945
|
+
description: >-
|
|
38946
|
+
Metadata to merge into the inbox's existing metadata. Keys you
|
|
38947
|
+
include
|
|
38948
|
+
|
|
38949
|
+
are added or overwritten; keys you omit are left unchanged. To
|
|
38950
|
+
remove a
|
|
38951
|
+
|
|
38952
|
+
single key, send it with a null value. To clear all metadata, send
|
|
38953
|
+
|
|
38954
|
+
`metadata` as null. Provide at least one of `display_name` or
|
|
38955
|
+
`metadata`.
|
|
38648
38956
|
title: UpdateInboxRequest
|
|
38649
38957
|
type_inboxes:Email:
|
|
38650
38958
|
type: string
|
|
@@ -38667,6 +38975,9 @@ components:
|
|
|
38667
38975
|
$ref: '#/components/schemas/type_inboxes:DisplayName'
|
|
38668
38976
|
client_id:
|
|
38669
38977
|
$ref: '#/components/schemas/type_inboxes:ClientId'
|
|
38978
|
+
metadata:
|
|
38979
|
+
$ref: '#/components/schemas/type_inboxes:Metadata'
|
|
38980
|
+
description: Custom metadata attached to the inbox.
|
|
38670
38981
|
updated_at:
|
|
38671
38982
|
type: string
|
|
38672
38983
|
format: date-time
|
|
@@ -38717,9 +39028,7 @@ async function main() {
|
|
|
38717
39028
|
const client = new AgentMailClient({
|
|
38718
39029
|
apiKey: "YOUR_TOKEN_HERE",
|
|
38719
39030
|
});
|
|
38720
|
-
await client.pods.inboxes.update("pod_id", "inbox_id", {
|
|
38721
|
-
displayName: "display_name",
|
|
38722
|
-
});
|
|
39031
|
+
await client.pods.inboxes.update("pod_id", "inbox_id", {});
|
|
38723
39032
|
}
|
|
38724
39033
|
main();
|
|
38725
39034
|
|
|
@@ -38735,7 +39044,6 @@ client = AgentMail(
|
|
|
38735
39044
|
client.pods.inboxes.update(
|
|
38736
39045
|
pod_id="pod_id",
|
|
38737
39046
|
inbox_id="inbox_id",
|
|
38738
|
-
display_name="display_name",
|
|
38739
39047
|
)
|
|
38740
39048
|
|
|
38741
39049
|
```
|
|
@@ -38754,7 +39062,7 @@ func main() {
|
|
|
38754
39062
|
|
|
38755
39063
|
url := "https://api.agentmail.to/v0/pods/pod_id/inboxes/inbox_id"
|
|
38756
39064
|
|
|
38757
|
-
payload := strings.NewReader("{
|
|
39065
|
+
payload := strings.NewReader("{}")
|
|
38758
39066
|
|
|
38759
39067
|
req, _ := http.NewRequest("PATCH", url, payload)
|
|
38760
39068
|
|
|
@@ -38784,7 +39092,7 @@ http.use_ssl = true
|
|
|
38784
39092
|
request = Net::HTTP::Patch.new(url)
|
|
38785
39093
|
request["Authorization"] = 'Bearer <api_key>'
|
|
38786
39094
|
request["Content-Type"] = 'application/json'
|
|
38787
|
-
request.body = "{
|
|
39095
|
+
request.body = "{}"
|
|
38788
39096
|
|
|
38789
39097
|
response = http.request(request)
|
|
38790
39098
|
puts response.read_body
|
|
@@ -38797,7 +39105,7 @@ import com.mashape.unirest.http.Unirest;
|
|
|
38797
39105
|
HttpResponse<String> response = Unirest.patch("https://api.agentmail.to/v0/pods/pod_id/inboxes/inbox_id")
|
|
38798
39106
|
.header("Authorization", "Bearer <api_key>")
|
|
38799
39107
|
.header("Content-Type", "application/json")
|
|
38800
|
-
.body("{
|
|
39108
|
+
.body("{}")
|
|
38801
39109
|
.asString();
|
|
38802
39110
|
```
|
|
38803
39111
|
|
|
@@ -38808,9 +39116,7 @@ require_once('vendor/autoload.php');
|
|
|
38808
39116
|
$client = new \GuzzleHttp\Client();
|
|
38809
39117
|
|
|
38810
39118
|
$response = $client->request('PATCH', 'https://api.agentmail.to/v0/pods/pod_id/inboxes/inbox_id', [
|
|
38811
|
-
'body' => '{
|
|
38812
|
-
"display_name": "display_name"
|
|
38813
|
-
}',
|
|
39119
|
+
'body' => '{}',
|
|
38814
39120
|
'headers' => [
|
|
38815
39121
|
'Authorization' => 'Bearer <api_key>',
|
|
38816
39122
|
'Content-Type' => 'application/json',
|
|
@@ -38827,7 +39133,7 @@ var client = new RestClient("https://api.agentmail.to/v0/pods/pod_id/inboxes/inb
|
|
|
38827
39133
|
var request = new RestRequest(Method.PATCH);
|
|
38828
39134
|
request.AddHeader("Authorization", "Bearer <api_key>");
|
|
38829
39135
|
request.AddHeader("Content-Type", "application/json");
|
|
38830
|
-
request.AddParameter("application/json", "{
|
|
39136
|
+
request.AddParameter("application/json", "{}", ParameterType.RequestBody);
|
|
38831
39137
|
IRestResponse response = client.Execute(request);
|
|
38832
39138
|
```
|
|
38833
39139
|
|
|
@@ -38838,7 +39144,7 @@ let headers = [
|
|
|
38838
39144
|
"Authorization": "Bearer <api_key>",
|
|
38839
39145
|
"Content-Type": "application/json"
|
|
38840
39146
|
]
|
|
38841
|
-
let parameters = [
|
|
39147
|
+
let parameters = [] as [String : Any]
|
|
38842
39148
|
|
|
38843
39149
|
let postData = JSONSerialization.data(withJSONObject: parameters, options: [])
|
|
38844
39150
|
|
|
@@ -44405,6 +44711,9 @@ components:
|
|
|
44405
44711
|
type: string
|
|
44406
44712
|
format: date-time
|
|
44407
44713
|
description: Time at which entry was created.
|
|
44714
|
+
read_only:
|
|
44715
|
+
type: boolean
|
|
44716
|
+
description: Whether the entry is read-only and cannot be deleted via the API.
|
|
44408
44717
|
pod_id:
|
|
44409
44718
|
type: string
|
|
44410
44719
|
description: ID of pod.
|
|
@@ -44709,6 +45018,9 @@ components:
|
|
|
44709
45018
|
type: string
|
|
44710
45019
|
format: date-time
|
|
44711
45020
|
description: Time at which entry was created.
|
|
45021
|
+
read_only:
|
|
45022
|
+
type: boolean
|
|
45023
|
+
description: Whether the entry is read-only and cannot be deleted via the API.
|
|
44712
45024
|
pod_id:
|
|
44713
45025
|
type: string
|
|
44714
45026
|
description: ID of pod.
|
|
@@ -45027,6 +45339,9 @@ components:
|
|
|
45027
45339
|
type: string
|
|
45028
45340
|
format: date-time
|
|
45029
45341
|
description: Time at which entry was created.
|
|
45342
|
+
read_only:
|
|
45343
|
+
type: boolean
|
|
45344
|
+
description: Whether the entry is read-only and cannot be deleted via the API.
|
|
45030
45345
|
pod_id:
|
|
45031
45346
|
type: string
|
|
45032
45347
|
description: ID of pod.
|