title: UPS ShipmentRequest API JSON Notification shipping to access point
body: <p>I'm at a loss at the moment, I'm trying to add the option to send a package to a UPS Access Point, the documentation tells me I need to add a notification object for UAP (013) and for ADL (012)</p>
  
  <p>When I read the documentation the notification object is allowed maximum 3 times, normally in xml it would look like:</p>
  
  <pre><code>&lt;ShipmentServiceOptions&gt;
    &lt;Notification&gt;
      &lt;NotificationCode&gt;012&lt;/NotificationCode&gt;
      some other values ( here..)
    &lt;/Notification&gt;
        &lt;Notification&gt;
      &lt;NotificationCode&gt;013&lt;/NotificationCode&gt;
      some other values ( here..)
    &lt;/Notification&gt;
  &lt;/ShipmentServiceOptions&gt;
  </code></pre>
  
  <p>But since I'm using JSON I create an array of objects:</p>
  
  <pre><code>$Shipment['ShipmentServiceOptions']['Notification'][] = ['NotificationCode' =&gt; '012'];
  $Shipment['ShipmentServiceOptions']['Notification'][] = ['NotificationCode' =&gt; '013'];
  </code></pre>
  
  <p>when I json decode this complete array, it will look like:</p>
  
  <pre><code>{
  "Notification": [{
      "NotificationCode": "013",
      "EmailMessage": {
          "EMailAddress": "info@tom-it.nl",
          "UndeliverableEMailAddr": "info@tom-it.nl",
          "FromEMailAddress ": "fromemail@test.com",
          "FromName": "From Email"
      },
      "Locale": {
          "Language": "ENG",
          "Dialect": "US"
      }
  }, {
      "NotificationCode": "012",
      "EmailMessage": {
          "EMailAddress": "info@tom-it.nl",
          "UndeliverableEMailAddr": "info@tom-it.nl",
          "FromEMailAddress ": "From Email",
          "FromName": "From Name"
      },
      "Locale": {
          "Language": "ENG",
          "Dialect": "US"
      }
  }]
  </code></pre>
  
  <p>}</p>
  
  <p>This is a valid json object, but for some reason I keep getting the error:</p>
  
  <blockquote>
    <p>ADL notification code (012) and notification data (email or phone number) is required for hold for pickup at access point location shipment.</p>
  </blockquote>
  
  <p>When I flip the array values around I will get the error:</p>
  
  <blockquote>
    <p>UAP shipper notification code (013) and notification data (email or phone number) is required for UPS Access Point Delivery.</p>
  </blockquote>
  
  <p>This looks to me like only 1 value is being read from the array, and reading the documentation it leads me to believe it expects multiple Notification keys, but I really have no idea how I would add multiple Notification keys in json, which would invalidate the json object.. Any help would be greatly appreciated </p>
  
  <p>Edit</p>
  
  <p>when I convert the JSON object to look like this:</p>
  
  <pre><code>"ShipmentServiceOptions": [{
              "Notification": {
                  "NotificationCode": "013",
                  "EmailMessage": {
                      "EMailAddress": "info@tom-it.nl",
                      "UndeliverableEMailAddr": "info@tom-it.nl",
                      "FromEMailAddress ": "fromemail",
                      "FromName": "From Name"
                  },
                  "Locale": {
                      "Language": "ENG",
                      "Dialect": "US"
                  }
              }
          }, {
              "Notification": {
                  "NotificationCode": "012",
                  "EmailMessage": {
                      "EMailAddress": "info@tom-it.nl",
                      "UndeliverableEMailAddr": "info@tom-it.nl",
                      "FromEMailAddress ": "fromemail",
                      "FromName": "From Name"
                  },
                  "Locale": {
                      "Language": "ENG",
                      "Dialect": "US"
                  }
              }
          }],
  </code></pre>
  
  <p>It gives me the this error:</p>
  
  <blockquote>
    <p>ADL notification code (012) and notification data (email or phone number) is required for hold for pickup at access point location shipment.</p>
  </blockquote>
  
  <p>Swapping around the items doesn't change the error</p>