|
1 | 1 | # generated by datamodel-codegen: |
2 | 2 | # filename: openapi.yaml |
3 | | -# timestamp: 2026-09-10T08:35:08+00:00 |
| 3 | +# timestamp: 2026-09-10T08:48:51+00:00 |
4 | 4 |
|
5 | 5 | from __future__ import annotations |
6 | 6 |
|
@@ -3827,6 +3827,32 @@ class ReferredProduct(BaseModel): |
3827 | 3827 | """ |
3828 | 3828 |
|
3829 | 3829 |
|
| 3830 | +class Location(BaseModel): |
| 3831 | + """ |
| 3832 | + WhatsApp only. The location pin the user shared, forwarded |
| 3833 | + verbatim from Meta. The message `text` is only the emoji preview |
| 3834 | + (`📍 <name>`); the coordinates live here. |
| 3835 | +
|
| 3836 | + """ |
| 3837 | + |
| 3838 | + latitude: float | None = None |
| 3839 | + """ |
| 3840 | + Latitude in decimal degrees. |
| 3841 | + """ |
| 3842 | + longitude: float | None = None |
| 3843 | + """ |
| 3844 | + Longitude in decimal degrees. |
| 3845 | + """ |
| 3846 | + name: str | None = None |
| 3847 | + """ |
| 3848 | + Location name, when the user shared a named place. |
| 3849 | + """ |
| 3850 | + address: str | None = None |
| 3851 | + """ |
| 3852 | + Street address, when Meta sends one. |
| 3853 | + """ |
| 3854 | + |
| 3855 | + |
3830 | 3856 | class ContactsOrigin(str, Enum): |
3831 | 3857 | """ |
3832 | 3858 | WhatsApp only. How the contact card was shared. |
@@ -4081,6 +4107,13 @@ class Metadata(BaseModel): |
4081 | 4107 | inbound text carries Meta's `context.referred_product` (the user |
4082 | 4108 | tapped "Message business" on a product). Forwarded verbatim. |
4083 | 4109 |
|
| 4110 | + """ |
| 4111 | + location: Location | None = None |
| 4112 | + """ |
| 4113 | + WhatsApp only. The location pin the user shared, forwarded |
| 4114 | + verbatim from Meta. The message `text` is only the emoji preview |
| 4115 | + (`📍 <name>`); the coordinates live here. |
| 4116 | +
|
4084 | 4117 | """ |
4085 | 4118 | contacts: List[Dict[str, Any]] | None = None |
4086 | 4119 | """ |
@@ -4367,11 +4400,59 @@ class Message1(BaseModel): |
4367 | 4400 | """ |
4368 | 4401 |
|
4369 | 4402 |
|
| 4403 | +class Location1(BaseModel): |
| 4404 | + """ |
| 4405 | + WhatsApp only. The location pin this message carries, in the same |
| 4406 | + shape the inbox send API accepts. Present on API sends that passed |
| 4407 | + `location`, and on Coexistence echoes of a pin shared from the |
| 4408 | + WhatsApp Business app. The message `text` is only the emoji |
| 4409 | + preview (`📍 <name>`); the pin itself lives here. |
| 4410 | +
|
| 4411 | + """ |
| 4412 | + |
| 4413 | + latitude: float | None = None |
| 4414 | + """ |
| 4415 | + Latitude in decimal degrees. |
| 4416 | + """ |
| 4417 | + longitude: float | None = None |
| 4418 | + """ |
| 4419 | + Longitude in decimal degrees. |
| 4420 | + """ |
| 4421 | + name: str | None = None |
| 4422 | + """ |
| 4423 | + Location name, when one was given. |
| 4424 | + """ |
| 4425 | + address: str | None = None |
| 4426 | + """ |
| 4427 | + Street address, when one was given. |
| 4428 | + """ |
| 4429 | + |
| 4430 | + |
4370 | 4431 | class Metadata1(BaseModel): |
4371 | 4432 | """ |
4372 | | - Platform-specific context for the sent message. The key is present only when the send carried some context, and absent otherwise: it is never null and never an empty object. |
| 4433 | + Platform-specific context for the sent message: a quote-reply reference, a WhatsApp location pin or WhatsApp contact cards. The key is present only when the send carried some context, and absent otherwise: it is never null and never an empty object. Read it to tell a location or contact-card message from a text one without a GET on the message. |
| 4434 | + """ |
| 4435 | + |
| 4436 | + location: Location1 | None = None |
| 4437 | + """ |
| 4438 | + WhatsApp only. The location pin this message carries, in the same |
| 4439 | + shape the inbox send API accepts. Present on API sends that passed |
| 4440 | + `location`, and on Coexistence echoes of a pin shared from the |
| 4441 | + WhatsApp Business app. The message `text` is only the emoji |
| 4442 | + preview (`📍 <name>`); the pin itself lives here. |
| 4443 | +
|
4373 | 4444 | """ |
| 4445 | + contacts: List[Dict[str, Any]] | None = None |
| 4446 | + """ |
| 4447 | + WhatsApp only. The contact cards this message carries. On API |
| 4448 | + sends this is the `contacts` array exactly as given to the inbox |
| 4449 | + send API (`name`, `phones[].phone` / `type`, `emails[]`); on |
| 4450 | + Coexistence echoes of a card shared from the WhatsApp Business |
| 4451 | + app it is Meta's shape (`phones[].wa_id`, `vcard`). The message |
| 4452 | + `text` is only the emoji preview (`👤 <name>`); the cards live |
| 4453 | + here. |
4374 | 4454 |
|
| 4455 | + """ |
4375 | 4456 | quotedMessageId: str | None = None |
4376 | 4457 | """ |
4377 | 4458 | `platformMessageId` of the message this send is a quote-reply to. |
@@ -4420,7 +4501,7 @@ class WebhookPayloadMessageSent(BaseModel): |
4420 | 4501 | account: InboxWebhookAccount |
4421 | 4502 | metadata: Metadata1 | None = None |
4422 | 4503 | """ |
4423 | | - Platform-specific context for the sent message. The key is present only when the send carried some context, and absent otherwise: it is never null and never an empty object. |
| 4504 | + Platform-specific context for the sent message: a quote-reply reference, a WhatsApp location pin or WhatsApp contact cards. The key is present only when the send carried some context, and absent otherwise: it is never null and never an empty object. Read it to tell a location or contact-card message from a text one without a GET on the message. |
4424 | 4505 | """ |
4425 | 4506 | timestamp: AwareDatetime |
4426 | 4507 | """ |
|
0 commit comments