MPDX Developers
HomeHelp
Production
Production
  • Changelog
  • README
  • org_data_transfer
  • README
    • README
      • Account Lists
        • :Account List
        • Analytics
        • Chalkline Mail
        • Coaches
        • Designation Accounts
        • Donations
        • Donor Accounts
        • Entries
        • Financial Accounts
        • Imports
          • Csv
          • Google
          • Tnt
          • Tnt Data Sync
        • Invites
        • Mail Chimp Account
        • Merge
        • Notification Preferences
          • Bulk
        • Notifications
        • Pledges
        • Prayer Letters Account
        • Users
        • :account_list_id
          • Donations
        • :account_list_id
          • donations
            • Bulk
      • README
        • Impersonation
        • Organizations
        • Resets
      • Announcements
      • Appeals
        • Appeal Contacts
          • Bulk
        • Excluded Appeal Contacts
          • Bulk
      • Background Batches
      • Batch
      • Coaching
        • Answer Sets
        • Answers
        • Questions
      • Constants
      • Contacts
        • Addresses
        • Alma Mater Names
        • Analytics
        • Bulk
        • Church Names
        • Duplicates
        • README
        • Exports
          • Mailing
        • Filters
        • Merges
        • Partner Giving Analysis Filters
        • People
          • Bulk
          • Email Addresses
          • Facebook Accounts
          • Linkedin Accounts
          • Merges
          • Phones
          • Relationships
          • Twitter Accounts
          • Websites
        • Referrals
        • Referrers
        • Tags
          • Bulk
      • Deleted Records
      • Organizations
        • Account Lists
          • Account List Coaches
          • Account List Users
          • Invites
        • Admins
        • Contacts
        • Impersonation
        • Invites
      • Public
        • Designation Accounts
          • Subscriptions
      • README
        • Activity Results
        • Appointment Results
        • Donation Histories
        • Donation Monthly Totals
        • Donor Currency Donations
        • Entry Histories
        • Expected Monthly Totals
        • Goal Progress
        • Monthly Giving Graph
        • Monthly Losses Graphs
        • Partner Giving Analysis
        • People With Anniversaries
        • People With Birthdays
        • Pledge Histories
        • Salary Currency Donations
        • Tag Histories
        • Year Donations
      • Tasks
        • Analytics
        • Comments
        • Filters
        • Tags
      • README
        • Analytics
      • User
        • Account List Coaches
        • Announcements
        • Authenticate
        • Devices
        • Google Accounts
          • Google Integrations
        • Key Accounts
        • Notifications
        • Options
        • Organization Accounts
Powered by GitBook
On this page
  • Device [LIST]
  • Request
  • Response
  • Fields
  • Device [POST]
  • Request
  • Parameters
  • Response
  • Fields
  • Device [GET]
  • Request
  • Response
  • Fields
  • Device [DELETE]
  • Request
  • Response
  1. README
  2. README
  3. User

Devices

Devices Documentation

Device [LIST]

Device [LIST]

Request

Endpoint

GET /api/v2/user/devices
Content-Type: application/vnd.api+json

Body

Response

Headers

Content-Type: application/vnd.api+json; charset=utf-8
200 OK

Body

{
  "data": [
    {
      "id": "3cc5f497-2132-4582-ba96-b6d4649c65cb",
      "type": "user_devices",
      "attributes": {
        "created_at": "2022-01-12T17:18:43Z",
        "locale": "en",
        "platform": "GCM",
        "updated_at": "2022-01-12T17:18:43Z",
        "updated_in_db_at": "2022-01-12T17:18:43Z",
        "version": "0.0.1"
      },
      "relationships": {
        "user": {
          "data": {
            "id": "1c772015-fcb6-4719-bd3f-5523f1039405",
            "type": "users"
          }
        }
      }
    }
  ],
  "meta": {
    "pagination": {
      "page": 1,
      "per_page": 25,
      "total_count": 1,
      "total_pages": 1
    },
    "sort": null,
    "filter": {
    }
  }
}

Fields

data

Type [Device]

Description An array of Device Objects

Device [POST]

Device [POST]

Request

Endpoint

POST /api/v2/user/devices
Content-Type: application/vnd.api+json

Body

{
  "data": {
    "type": "user_devices",
    "attributes": {
      "locale": "en",
      "platform": "GCM",
      "token": "a5b4dddf-2cbe-4d72-ace1-3ef86626ff1e",
      "updated_in_db_at": "2022-01-12 17:18:43 UTC",
      "version": "0.0.1"
    }
  }
}

Parameters

Attributes

created_at

Type date

Description The timestamp of when this resource was created

Required No

locale

Type string

Description The locale set on the device (to localize push notifications sent to the device)

Required No

platform

Type string

Description The platform which the device is registered on (must be either APNS or GCM)

Required No

token

Type string

Description The token provided by the platform needed for the server to send notifications to the device

Required No

updated_at

Type date

Description The timestamp of when this resource was last updated

Required No

updated_in_db_at

Type date

Description This is to be used as a reference for the last time the resource was updated in the remote database - specifically for when data is updated while the client is offline.

Required No

version

Type string

Description The version of the client app installed on the device

Required No

Response

Headers

Content-Type: application/vnd.api+json; charset=utf-8
201 Created

Body

{
  "data": {
    "id": "880eac5d-83ef-41f7-abab-aad72d477ac6",
    "type": "user_devices",
    "attributes": {
      "created_at": "2022-01-12T17:18:43Z",
      "locale": "en",
      "platform": "GCM",
      "updated_at": "2022-01-12T17:18:43Z",
      "updated_in_db_at": "2022-01-12T17:18:43Z",
      "version": "0.0.1"
    },
    "relationships": {
      "user": {
        "data": {
          "id": "940acb1e-a98c-4638-98b9-172bcc6b9072",
          "type": "users"
        }
      }
    }
  }
}

Fields

Attributes

created_at

Type date

Description The timestamp of when this resource was created

locale

Type string

Description The locale set on the device (to localize push notifications sent to the device)

platform

Type string

Description The platform which the device is registered on (must be either APNS or GCM)

updated_at

Type date

Description The timestamp of when this resource was last updated

updated_in_db_at

Type date

Description This is to be used as a reference for the last time the resource was updated in the remote database - specifically for when data is updated while the client is offline.

version

Type string

Description The version of the client app installed on the device

Relationships

user.data

Type User

Description A user that this device is associated with

Device [GET]

Device [GET]

Request

Endpoint

GET /api/v2/user/devices/c4a3fb7a-ed8d-4d07-a499-fd09e3422b4f
Content-Type: application/vnd.api+json

Body

Response

Headers

Content-Type: application/vnd.api+json; charset=utf-8
200 OK

Body

{
  "data": {
    "id": "c4a3fb7a-ed8d-4d07-a499-fd09e3422b4f",
    "type": "user_devices",
    "attributes": {
      "created_at": "2022-01-12T17:18:43Z",
      "locale": "en",
      "platform": "GCM",
      "updated_at": "2022-01-12T17:18:43Z",
      "updated_in_db_at": "2022-01-12T17:18:43Z",
      "version": "0.0.1"
    },
    "relationships": {
      "user": {
        "data": {
          "id": "8e5501c4-0e3c-407f-a176-2d744536d75a",
          "type": "users"
        }
      }
    }
  }
}

Fields

Attributes

created_at

Type date

Description The timestamp of when this resource was created

locale

Type string

Description The locale set on the device (to localize push notifications sent to the device)

platform

Type string

Description The platform which the device is registered on (must be either APNS or GCM)

updated_at

Type date

Description The timestamp of when this resource was last updated

updated_in_db_at

Type date

Description This is to be used as a reference for the last time the resource was updated in the remote database - specifically for when data is updated while the client is offline.

version

Type string

Description The version of the client app installed on the device

Relationships

user.data

Type User

Description A user that this device is associated with

Device [DELETE]

Device [DELETE]

Request

Endpoint

DELETE /api/v2/user/devices/9d99d846-cb7b-4c67-836b-754812b93717
Content-Type: application/vnd.api+json

Body

Response

Headers

204 No Content

Body

PreviousAuthenticateNextGoogle Accounts

Last updated 3 years ago