Skip to content

Instantly share code, notes, and snippets.

@MikeLarned
Created May 16, 2012 04:47
Show Gist options
  • Select an option

  • Save MikeLarned/2707509 to your computer and use it in GitHub Desktop.

Select an option

Save MikeLarned/2707509 to your computer and use it in GitHub Desktop.
UrbanAirship Get Android / IOS Devices
public IEnumerable<IDevice> GetDevices()
{
var devices = new List<IDevice>();
var androidDevices = Http.Get<AndroidPushIdCollection>(GetApiUrl("apids/"), WithMasterSecret).Apids;
var iosDevices = Http.Get<DeviceTokenCollection>(GetApiUrl("device_tokens/"), WithMasterSecret).Device_Tokens;
devices.AddRange(androidDevices);
devices.AddRange(iosDevices);
return devices;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment