Profile Requirements

To deliver a push notification to a recipient over Airship, Courier must be provided the recipient’s Airship user id and devices. These values should be included in the recipient profile as airship.

{
  "message": {
    "template": "{{event.id}}",
    "to": {
      "airship": {
        "audience": {
          "named_user": "{{recipient.user_id}}"
        },
        "device_types": ["ios"]
      }
    },
    "data": {
      "username": "Steph Courier"
    }
  }
}

Override

You can use a provider override to replace what we send to Airship’s API. For example, you can use basic auth with your send request:

{
  "message": {
    "template": "ABCDEFGHIJKLMNOPQRSTUVWXYZ",
    "to": {
      "airship": {
        "audience": {
          "named_user": "{{recipient.user_id}}"
        },
        "device_types": ["ios"]
      }
    },
    "data": {
      "dataForPushMessage": true
    },
    "providers": {
      "airship": {
        "override": {
          "body": {},
          "headers": {
            "Authorization": "Basic {{EncodedAppKey:AppSecret}}"
          }
        }
      }
    }
  }
}

Everything inside of providers.airship.override will replace what we send to Airship’s API. You can see all the available options by visiting Airship’s website.

Tracking Events

Courier will include tracking URL information in the global_attributes data bag.

See Courier push notification tracking