Skip to content

getOutboundMessageDetails() is nesting events twice #153

@Maxwell2022

Description

@Maxwell2022
"name": "wildbit/postmark-php",
"version": "v6.0.9",

According to the API documentation: https://postmarkapp.com/developer/api/messages-api#outbound-message-details

When requesting message details, it should return an array of events. Dumping the response it's actually returning nested arrays:

Image

In order to access these events we need to target MessageEvents from MessageEvents:

foreach ($messageDetails->MessageEvents->MessageEvents as $event) {
  // got the event
}

I would expect to loop over events like this:

foreach ($messageDetails->MessageEvents as $event) {
  // got the event
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions