Events Version 1

Note: This documentation describes Version 1 of our API, which is now depreciated. It will continue to work, but it will not reveive any updates or bug fixes. We recommend you use Version 2 instead. Documentation for this resource for Version 2 of our API is available here.

This document describes the OSDI events collection and petition resource as implemented by the Action Network.

Events are a type of action created by the organizer or group associated with your API key that involves activists RSVPing for an event they would like to attend.

Events have summaries (titles) and can have descriptions, locations, dates, and times, and when activists sign them attendance resources are created representing the RSVP an activist made for that event.

Events are not deduplicated except on identifiers, to keep identifiers unique.

Sections:

Endpoints and URL structures

Endpoints:

https://actionnetwork.org/api/v1/events

https://actionnetwork.org/api/v1/event_campaigns/[event_campaign_id]/events

Event resources live at the above endpoints. The endpoints returns a collection of all events associated with your API key or all events associated with a specific event campaign.

URL Structures:

https://actionnetwork.org/api/v1/events/[id]

To address a specific event, use the identifier without the action_network: prefix to construct a URL, like https://actionnetwork.org/api/v1/events/d91b4b2e-ae0e-4cd3-9ed7-d0ec501b0bc3

Back To Top ↑

Field names and descriptions

Field Name Type Required on POST Description
identifiers array[] An array of identifiers in the format [system name]:[id]. See the general concepts document for more information about identifiers.
originating_system string Yes A human readable string identifying where this event originated. May be used in the user interface for this purpose.
created_at datetime The date and time the resource was created. System generated, not editable.
modified_at datetime The date and time the resource was last modified. System generated, not editable.
summary string Yes The event's title.
description string The event's description. May contain HTML.
action_network:event_instructions string The event's instructions for activists, visible after they RSVP. May contain HTML.
url string The URL to this event on the Action Network. Only present for events created with our user interface. Not editable.
start datetime The start date and time of the event.
location hash A hash representing the location of the event.
location.venue string The venue of the event. (ex: Jane White Hall)
location.address_lines array[] An array of strings representing the event's street address. We will ignore any beyond the first.
location.locality string A city or other local administrative area. This will be overwritten based on our geocoding.
location.region string State / subdivision codes according to ISO 3166-2 (Final 2 alpha digits). This will be overwritten based on our geocoding.
location.postal_code string Yes Region specific postal code such as ZIP code.
location.country string Country code according to ISO 3166-1 Alpha-2. This will be overwritten based on our geocoding.
location.language string Language in which the address is recorder -- language code according to ISO 639. This will be overwritten and set to English.
location.location hash A hash of location information for the address. This will be overwritten based on our geocoding.
location.location.latitude float Geolocation latitude. This will be overwritten based on our geocoding.
location.location.longitude float Geolocation longitude. This will be overwritten based on our geocoding.
location.location.accuracy enum One of ["Rooftop" "Approximate"]. This will be overwritten based on our geocoding.
osdi:creator osdi:person* An embedded person representing the user who created this event. If you do not assign a creator, we will assign one based on your API key. Cannot be edited once created.
osdi:organizer osdi:person* An embedded person representing the user who is organizing this event. System generated, always the same as osdi:creator, not editable.
total_accepted integer A system generated count of the number of attendance resources on this petition. Not editable.
action_network:event_campaign_id string The Action Network identifier to an event campaign this event is part of. Action Network-only feature. Not editable.
status enum The status of the event. One of ["confirmed" "tentative" "cancelled"] System generated, will always be confirmed, not editable.
transparence enum Whether this event should block on online calendars. One of ["opaque" "transparent"]. System generated, will always be opaque, not editable.
visibility enum Whether this event is visible in search results or not. One of ["public" "private"]. System generated, not editable.
guestsCanInviteOthers boolean Whether guests can invite others to the event. System generated, will always be true, not editable.
reminders array[] An array of hashes indicating when automatic reminders are to be send. System generated, not editable.
reminders.method enum The method of this reminder. One of ["email" "sms"]. System generated, will always be email, not editable.
reminders.minutes integer The number of minutes before the event reminders are scheduled to be sent. System generated, will always be 1440 (24 hours), not editable.
action_network:sponsor hash A hash of the sponsoring group of this event. Action Network-only feature. Automatically added if you post using a group API key. System generated, not editable.
action_network:sponsor.summary string The name of the sponsoring group.
action_network:sponsor.url string The URL to the group's public page.
Back To Top ↑

Links

Link Name Description
self A link to this individual event resource.
osdi:attendance A link to a collection of all attendance resources associated with this event. Click here for attendance documentation.
osdi:creator A link to the person who created this event. Click here for people documentation.
osdi:organizer A link to the person who organized this event. Click here for people documentation.
action_network:event_campaign A link to the event campaign this event is part of. Action Network-only feature. Click here for event campaign documentation.
action_network:embed A link to embed code for this event. Action Network-only feature. Click here for embed documentation.
Back To Top ↑

Scenario: Retrieving a collection of event resources (GET)

Event resources are sometimes presented as collections of events. For example, calling the events endpoint will return a collection of all the events associated with your API key.

Request

						
GET https://actionnetwork.org/api/v1/events/

Header:
api-key:[your api key here]
					

Response

						
200 OK

Content-Type: application/hal+json
Cache-Control: max-age=0, private, must-revalidate


{
  "total_pages": 10,
  "per_page": 25,
  "page": 1,
  "total_records": 250,
  "_links": {
    "next": {
      "href": "https://actionnetwork.org/api/v1/events?page=2"
    },
    "self": {
      "href": "https://actionnetwork.org/api/v1/events"
    },
    "osdi:events": [
      {
        "href": "https://actionnetwork.org/api/v1/events/8a625981-67a4-4457-8b55-2e30b267b2c2"
      },
      {
        "href": "https://actionnetwork.org/api/v1/events/3f976089-4477-461f-9d2f-1d741aa9b7a8"
      },
      //truncated for brevity
    ],
    "curies": [
      {
        "name": "osdi",
        "href": "https://actionnetwork.org/docs/v1/{rel}",
        "templated": true
      },
      {
        "name": "action_network",
        "href": "https://actionnetwork.org/docs/v1/{rel}",
        "templated": true
      }
    ]
  },
  "_embedded": {
    "osdi:events": [
      {
        "originating_system": "FreeEvents.com",
        "identifiers": [
          "action_network:8a625981-67a4-4457-8b55-2e30b267b2c2",
          "free_events:1"
        ],
        "status": "confirmed",
        "created_at": "2014-03-18T22:17:36Z",
        "modified_at": "2014-03-19T14:07:41Z",
        "summary": "House Party for Justice",
        "transparence": "opaque",
        "visibility": "public",
        "guestsCanInviteOthers": true,
        "reminders": [
          {
            "method": "email",
            "minutes": 1440
          }
        ],
        "total_accepted": 5,
        "_embedded": {
          "osdi:creator": {
            "given_name": "John",
            "family_name": "Doe",
            "identifiers": [
              "action_network:c945d6fe-929e-11e3-a2e9-12313d316c29"
            ],
            "created_at": "2014-03-18T22:17:36Z",
			"modified_at": "2014-03-19T14:07:41Z",
			"originating_system": "Action Network",
            "email_addresses": [
              {
                "primary": true,
                "address": "jdoe@mail.com"
              }
            ],
            "postal_addresses": [
              {
                "primary": true,
                "address_lines": [
                  "1600 Pennsylvania Ave"
                ],
                "locality": "Washington",
                "region": "DC",
                "postal_code": "20009",
                "country": "US",
                "language": "en",
                "location": {
                  "latitude": 32.345,
                  "longitude": -73.0729,
                  "accuracy": "Approximate"
                }
              }
            ],
            "_links": {
              "self": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
              },
              "osdi:question_answers": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/question_answers"
              },
              "osdi:attendance": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/attendance"
              },
              "osdi:signatures": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/signatures"
              },
              "osdi:submissions": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/submissions"
              },
              "osdi:donations": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/donations"
              }
            }
          },
          "osdi:organizer": {
            "given_name": "John",
            "family_name": "Doe",
            "identifiers": [
              "action_network:c945d6fe-929e-11e3-a2e9-12313d316c29"
            ],
            "created_at": "2014-03-18T22:17:36Z",
			"modified_at": "2014-03-19T14:07:41Z",
			"originating_system": "Action Network",
            "email_addresses": [
              {
                "primary": true,
                "address": "jdoe@mail.com"
              }
            ],
            "postal_addresses": [
              {
                "primary": true,
                "address_lines": [
                  "1600 Pennsylvania Ave"
                ],
                "locality": "Washington",
                "region": "DC",
                "postal_code": "20009",
                "country": "US",
                "language": "en",
                "location": {
                  "latitude": 32.345,
                  "longitude": -73.0729,
                  "accuracy": "Approximate"
                }
              }
            ],
            "_links": {
              "self": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
              },
              "osdi:question_answers": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/question_answers"
              },
              "osdi:attendance": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/attendance"
              },
              "osdi:signatures": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/signatures"
              },
              "osdi:submissions": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/submissions"
              },
              "osdi:donations": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/donations"
              }
            }
          }
        },
        "location": {
          "venue": "My House",
          "address_lines": [
            "1600 Pennsylvania Ave"
          ],
          "locality": "Washington",
          "region": "DC",
          "postal_code": "20009",
          "country": "US",
          "language": "en",
          "location": {
            "latitude": 33.1037330420451,
            "longitude": -72.0439414557911,
            "accuracy": "Rooftop"
          }
        },
        "_links": {
          "self": {
            "href": "https://actionnetwork.org/api/v1/events/8a625981-67a4-4457-8b55-2e30b267b2c2"
          },
          "osdi:attendance": {
            "href": "https://actionnetwork.org/api/v1/events/8a625981-67a4-4457-8b55-2e30b267b2c2/attendance"
          },
          "osdi:organizer": {
            "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
          },
          "osdi:creator": {
            "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
          },
          "action_network:embed": {
            "href": "https://actionnetwork.org/api/v1/events/8a625981-67a4-4457-8b55-2e30b267b2c2/embed"
          }
        }
      },
      {
        "identifiers": [
          "action_network:3f976089-4477-461f-9d2f-1d741aa9b7a8"
        ],
        "status": "confirmed",
        "created_at": "2014-03-18T21:08:18Z",
        "modified_at": "2014-03-18T22:15:11Z",
        "originating_system": "Action Network"
        "summary": "Movie Screening",
        "description": "<p>Come watch this awesome movie!</p>",
        "action_network:event_instructions": "<p>Feel free to bring a friend</p>",
        "url": "https://actionnetwork.org/events/movie-screening",
        "start": "2014-03-22T17:45:00Z",
        "transparence": "opaque",
        "visibility": "public",
        "guestsCanInviteOthers": true,
        "reminders": [
          {
            "method": "email",
            "minutes": 1440
          }
        ],
        "total_accepted": 7,
        "action_network:sponsor": {
          "summary": "Progressive Action Now",
          "url": "https://actionnetwork.org/groups/progressive-action-now"
        },
        "_embedded": {
          "osdi:creator": {
            "given_name": "John",
            "family_name": "Doe",
            "identifiers": [
              "action_network:c945d6fe-929e-11e3-a2e9-12313d316c29"
            ],
            "created_at": "2014-03-18T22:17:36Z",
			"modified_at": "2014-03-19T14:07:41Z",
			"originating_system": "Action Network",
            "email_addresses": [
              {
                "primary": true,
                "address": "jdoe@mail.com"
              }
            ],
            "postal_addresses": [
              {
                "primary": true,
                "address_lines": [
                  "1600 Pennsylvania Ave"
                ],
                "locality": "Washington",
                "region": "DC",
                "postal_code": "20009",
                "country": "US",
                "language": "en",
                "location": {
                  "latitude": 32.345,
                  "longitude": -73.0729,
                  "accuracy": "Approximate"
                }
              }
            ],
            "_links": {
              "self": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
              },
              "osdi:question_answers": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/question_answers"
              },
              "osdi:attendance": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/attendance"
              },
              "osdi:signatures": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/signatures"
              },
              "osdi:submissions": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/submissions"
              },
              "osdi:donations": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/donations"
              }
            }
          },
          "osdi:organizer": {
            "given_name": "John",
            "family_name": "Doe",
            "identifiers": [
              "action_network:c945d6fe-929e-11e3-a2e9-12313d316c29"
            ],
            "created_at": "2014-03-18T22:17:36Z",
			"modified_at": "2014-03-19T14:07:41Z",
			"originating_system": "Action Network",
            "email_addresses": [
              {
                "primary": true,
                "address": "jdoe@mail.com"
              }
            ],
            "postal_addresses": [
              {
                "primary": true,
                "address_lines": [
                  "1600 Pennsylvania Ave"
                ],
                "locality": "Washington",
                "region": "DC",
                "postal_code": "20009",
                "country": "US",
                "language": "en",
                "location": {
                  "latitude": 32.345,
                  "longitude": -73.0729,
                  "accuracy": "Approximate"
                }
              }
            ],
            "_links": {
              "self": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
              },
              "osdi:question_answers": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/question_answers"
              },
              "osdi:attendance": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/attendance"
              },
              "osdi:signatures": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/signatures"
              },
              "osdi:submissions": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/submissions"
              },
              "osdi:donations": {
                "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/donations"
              }
            }
          }
        },
        "location": {
          "venue": "My house",
          "address_lines": [
            "1600 Pennsylvania Ave"
          ],
          "locality": "Washington",
          "region": "DC",
          "postal_code": "20009",
          "country": "US",
          "language": "en",
          "location": {
            "latitude": 32.9135624691629,
            "longitude": -76.0487183148486,
            "accuracy": "Rooftop"
          }
        },
        "_links": {
          "self": {
            "href": "https://actionnetwork.org/api/v1/events/3f976089-4477-461f-9d2f-1d741aa9b7a8"
          },
          "osdi:attendance": {
            "href": "https://actionnetwork.org/api/v1/events/3f976089-4477-461f-9d2f-1d741aa9b7a8/attendance"
          },
          "osdi:organizer": {
            "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
          },
          "osdi:creator": {
            "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
          },
          "action_network:embed": {
            "href": "https://actionnetwork.org/api/v1/events/3f976089-4477-461f-9d2f-1d741aa9b7a8/embed"
          }
        }
      },
      //truncated for brevity
    ]
  }
}
					
Back To Top ↑

Scenario: Retrieving an individual event resource (GET)

Calling an individual event resource will return the resource directly, along with all associated fields and appropriate links to additional information about the event.

Request

						
GET https://actionnetwork.org/api/v1/events/8a625981-67a4-4457-8b55-2e30b267b2c2

Header:
api-key:[your api key here]
					

Response

						
200 OK

Content-Type: application/hal+json
Cache-Control: max-age=0, private, must-revalidate


{
  "originating_system": "FreeEvents.com",
  "identifiers": [
    "action_network:8a625981-67a4-4457-8b55-2e30b267b2c2",
    "free_events:1"
  ],
  "status": "confirmed",
  "created_at": "2014-03-18T22:17:36Z",
  "modified_at": "2014-03-19T14:07:41Z",
  "summary": "House Party for Justice",
  "transparence": "opaque",
  "visibility": "public",
  "guestsCanInviteOthers": true,
  "reminders": [
    {
      "method": "email",
      "minutes": 1440
    }
  ],
  "total_accepted": 5,
  "_embedded": {
    "osdi:creator": {
      "given_name": "John",
      "family_name": "Doe",
      "identifiers": [
        "action_network:c945d6fe-929e-11e3-a2e9-12313d316c29"
      ],
      "created_at": "2014-03-18T22:17:36Z",
	  "modified_at": "2014-03-19T14:07:41Z",
	  "originating_system": "Action Network",
      "email_addresses": [
        {
          "primary": true,
          "address": "jdoe@mail.com"
        }
      ],
      "postal_addresses": [
        {
          "primary": true,
          "address_lines": [
            "1600 Pennsylvania Ave"
          ],
          "locality": "Washington",
          "region": "DC",
          "postal_code": "20009",
          "country": "US",
          "language": "en",
          "location": {
            "latitude": 32.345,
            "longitude": -73.0729,
            "accuracy": "Approximate"
          }
        }
      ],
      "_links": {
        "self": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
        },
        "osdi:question_answers": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/question_answers"
        },
        "osdi:attendance": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/attendance"
        },
        "osdi:signatures": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/signatures"
        },
        "osdi:submissions": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/submissions"
        },
        "osdi:donations": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/donations"
        },
        "curies": [
          {
            "name": "osdi",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          },
          {
            "name": "action_network",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          }
        ]
      }
    },
    "osdi:organizer": {
      "given_name": "John",
      "family_name": "Doe",
      "identifiers": [
        "action_network:c945d6fe-929e-11e3-a2e9-12313d316c29"
      ],
      "created_at": "2014-03-18T22:17:36Z",
	  "modified_at": "2014-03-19T14:07:41Z",
	  "originating_system": "Action Network",
      "email_addresses": [
        {
          "primary": true,
          "address": "jdoe@mail.com"
        }
      ],
      "postal_addresses": [
        {
          "primary": true,
          "address_lines": [
            "1600 Pennsylvania Ave"
          ],
          "locality": "Washington",
          "region": "DC",
          "postal_code": "20009",
          "country": "US",
          "language": "en",
          "location": {
            "latitude": 32.345,
            "longitude": -73.0729,
            "accuracy": "Approximate"
          }
        }
      ],
      "_links": {
        "self": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
        },
        "osdi:question_answers": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/question_answers"
        },
        "osdi:attendance": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/attendance"
        },
        "osdi:signatures": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/signatures"
        },
        "osdi:submissions": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/submissions"
        },
        "osdi:donations": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/donations"
        },
        "curies": [
          {
            "name": "osdi",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          },
          {
            "name": "action_network",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          }
        ]
      }
    }
  },
  "location": {
    "venue": "My House",
    "address_lines": [
      "1600 Pennsylvania Ave"
    ],
    "locality": "Washington",
    "region": "DC",
    "postal_code": "20009",
    "country": "US",
    "language": "en",
    "location": {
      "latitude": 33.1037330420451,
      "longitude": -72.0439414557911,
      "accuracy": "Rooftop"
    }
  },  
  "_links": {
    "self": {
      "href": "https://actionnetwork.org/api/v1/events/8a625981-67a4-4457-8b55-2e30b267b2c2"
    },
    "osdi:attendance": {
      "href": "https://actionnetwork.org/api/v1/events/8a625981-67a4-4457-8b55-2e30b267b2c2/attendance"
    },
    "osdi:organizer": {
      "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
    },
    "osdi:creator": {
      "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
    },
    "action_network:embed": {
      "href": "https://actionnetwork.org/api/v1/events/8a625981-67a4-4457-8b55-2e30b267b2c2/embed"
    },
    "curies": [
      {
        "name": "osdi",
        "href": "https://actionnetwork.org/docs/v1/{rel}",
        "templated": true
      },
      {
        "name": "action_network",
        "href": "https://actionnetwork.org/docs/v1/{rel}",
        "templated": true
      }
    ]
  }
}
					
Back To Top ↑

Scenario: Creating a new event (POST)

You can post a new event to the events endpoint and a event resource will be created in our system.

Note: Events created via the API in this way are not equivalent to events created with our user interface. API-created events will not show up in lists of all of your actions on your dashboard of group page, they will not be given a URL on actionnetwork.org where people can sign, they will not have individual manage pages for statistics, and they will not send out reminders. Rather, once they have at least one attendance, they will show up as actions available for selection in our targeting interface, allowing you to select all people who have taken action on that event for reports or email targeting.

In the targeting interface, they will show up in the format [1, (originating system) Event], (summary). For example, an event with the originating system "FreeEvents.com" and the summary "My Free Event" will show up in the targeting interface as [1, FreeEvents.com Event], My Free Event so you can easily identify what it is and where it came from when doing your targeting.

Request

						
POST https://actionnetwork.org/api/v1/events

Header:
Content-Type: application/json
api-key:[your api key here]
						

{	
  "identifiers": [
    "free_events:1"
  ],
  "summary": "My Free Event",
  "originating_system": "FreeEvents.com"
}
					

Response

						
200 OK

Content-Type: application/hal+json
Cache-Control: max-age=0, private, must-revalidate



{
  "originating_system": "FreeEvents.com",
  "identifiers": [
    "free_events:1",
    "action_network:21789f03-0180-45d3-853c-91bd6fdc8c07"
  ],
  "status": "confirmed",
  "created_at": "2014-03-26T21:02:09Z",
  "modified_at": "2014-03-26T21:02:09Z",
  "summary": "My Free Event",
  "transparence": "opaque",
  "visibility": "public",
  "guestsCanInviteOthers": true,
  "reminders": [
    {
      "method": "email",
      "minutes": 1440
    }
  ],
  "total_accepted": 0,
  "_embedded": {
    "osdi:creator": {
      "given_name": "John",
      "family_name": "Doe",
      "identifiers": [
        "action_network:c945d6fe-929e-11e3-a2e9-12313d316c29"
      ],
      "created_at": "2014-03-18T22:17:36Z",
	  "modified_at": "2014-03-19T14:07:41Z",
	  "originating_system": "Action Network",
      "email_addresses": [
        {
          "primary": true,
          "address": "jdoe@mail.com"
        }
      ],
      "postal_addresses": [
        {
          "primary": true,
          "address_lines": [
            "1600 Pennsylvania Ave"
          ],
          "locality": "Washington",
          "region": "DC",
          "postal_code": "20009",
          "country": "US",
          "language": "en",
          "location": {
            "latitude": 32.345,
            "longitude": -73.0729,
            "accuracy": "Approximate"
          }
        }
      ],
      "_links": {
        "self": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
        },
        "osdi:question_answers": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/question_answers"
        },
        "osdi:attendance": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/attendance"
        },
        "osdi:signatures": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/signatures"
        },
        "osdi:submissions": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/submissions"
        },
        "osdi:donations": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/donations"
        },
        "curies": [
          {
            "name": "osdi",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          },
          {
            "name": "action_network",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          }
        ]
      }
    },
    "osdi:organizer": {
      "given_name": "John",
      "family_name": "Doe",
      "identifiers": [
        "action_network:c945d6fe-929e-11e3-a2e9-12313d316c29"
      ],
      "created_at": "2014-03-18T22:17:36Z",
	  "modified_at": "2014-03-19T14:07:41Z",
	  "originating_system": "Action Network",
      "email_addresses": [
        {
          "primary": true,
          "address": "jdoe@mail.com"
        }
      ],
      "postal_addresses": [
        {
          "primary": true,
          "address_lines": [
            "1600 Pennsylvania Ave"
          ],
          "locality": "Washington",
          "region": "DC",
          "postal_code": "20009",
          "country": "US",
          "language": "en",
          "location": {
            "latitude": 32.345,
            "longitude": -73.0729,
            "accuracy": "Approximate"
          }
        }
      ],
      "_links": {
        "self": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
        },
        "osdi:question_answers": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/question_answers"
        },
        "osdi:attendance": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/attendance"
        },
        "osdi:signatures": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/signatures"
        },
        "osdi:submissions": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/submissions"
        },
        "osdi:donations": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/donations"
        },
        "curies": [
          {
            "name": "osdi",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          },
          {
            "name": "action_network",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          }
        ]
      }
    }
  },
  "location": {
    "region": "",
    "country": "US",
    "language": "en",
    "location": {
      "latitude": 39.7599977890005,
      "longitude": -98.4999989109997,
      "accuracy": "Approximate"
    }
  },
  "_links": {
    "self": {
      "href": "https://actionnetwork.org/api/v1/events/21789f03-0180-45d3-853c-91bd6fdc8c07"
    },
    "osdi:attendance": {
      "href": "https://actionnetwork.org/api/v1/events/21789f03-0180-45d3-853c-91bd6fdc8c07/attendance"
    },
    "osdi:organizer": {
      "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
    },
    "osdi:creator": {
      "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
    },
    "action_network:embed": {
      "href": "https://actionnetwork.org/api/v1/events/21789f03-0180-45d3-853c-91bd6fdc8c07/embed"
    },
    "curies": [
      {
        "name": "osdi",
        "href": "https://actionnetwork.org/docs/v1/{rel}",
        "templated": true
      },
      {
        "name": "action_network",
        "href": "https://actionnetwork.org/docs/v1/{rel}",
        "templated": true
      }
    ]
  }
}
					

In the above example, you can see how the foreign identifier being posted is merged into the identifiers array. We will intelligently search and deduplicate based on foreign and native identifiers. So if you post an event with an identifier that matches one already assigned to an event resource, your POST request will update that resource with new information instead of creating a duplicate.

You can post an event with a creator link as well, if you want to assign the event to a specific Action Network user, like so:

						
POST https://actionnetwork.org/api/v1/petitions

Header:
Content-Type: application/json
api-key:[your api key here]
						

{	
  "identifiers": [
    "free_events:1"
  ],
  "summary": "My Free Event",
  "originating_system": "FreeEvents.com"
  "_links" : {
    "osdi:creator" : { 
      "href" : "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29" 
    }
  }
}
					

The link must be a valid person resource and must be associated with your API key for it to be accepted. If your API key is for an individual account, then the link must be to your account's person resource. If your API key is for a group, then the link must be to a member of administrator of your group. If no link or an invalid link is provided, the event will be assigned to your API key's account person record or to the original creator of the group, whichever is appropriate. If a creator is explicitly set, people who take action will be added to that creator's personal email list. Otherwise, the creator is has no effect on what email list people who attend the event are subscribed to.

And of course you can post an event with more fields (such as location fields) if you'd like, but they are not required.

Back To Top ↑

Scenario: Modifying an event (PUT)

You can modify an existing event by using PUT on its individual endpoint.

Request

						
PUT https://actionnetwork.org/api/v1/events/21789f03-0180-45d3-853c-91bd6fdc8c07

Header:
Content-Type: application/json
api-key:[your api key here]
						

{	
  "identifiers": [
    "free_events:2"
  ],
  "summary": "My Free Event With A New Name",
  "description": "This is my free event description"
}
					

Response

						
200 OK

Content-Type: application/hal+json
Cache-Control: max-age=0, private, must-revalidate


{
  "originating_system": "FreeEvents.com",
  "identifiers": [
    "free_events:1",
    "action_network:21789f03-0180-45d3-853c-91bd6fdc8c07",
    "free_events:2"
  ],
  "status": "confirmed",
  "created_at": "2014-03-26T21:02:09Z",
  "modified_at": "2014-03-26T21:06:13Z",
  "summary": "My Free Event With A New Name",
  "description": "This is my free event description",
  "transparence": "opaque",
  "visibility": "public",
  "guestsCanInviteOthers": true,
  "reminders": [
    {
      "method": "email",
      "minutes": 1440
    }
  ],
  "total_accepted": 0,
  "_embedded": {
    "osdi:creator": {
      "given_name": "John",
      "family_name": "Doe",
      "identifiers": [
        "action_network:c945d6fe-929e-11e3-a2e9-12313d316c29"
      ],
      "created_at": "2014-03-18T22:17:36Z",
	  "modified_at": "2014-03-19T14:07:41Z",
	  "originating_system": "Action Network",
      "email_addresses": [
        {
          "primary": true,
          "address": "jdoe@mail.com"
        }
      ],
      "postal_addresses": [
        {
          "primary": true,
          "address_lines": [
            "1600 Pennsylvania Ave"
          ],
          "locality": "Washington",
          "region": "DC",
          "postal_code": "20009",
          "country": "US",
          "language": "en",
          "location": {
            "latitude": 32.345,
            "longitude": -73.0729,
            "accuracy": "Approximate"
          }
        }
      ],
      "_links": {
        "self": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
        },
        "osdi:question_answers": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/question_answers"
        },
        "osdi:attendance": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/attendance"
        },
        "osdi:signatures": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/signatures"
        },
        "osdi:submissions": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/submissions"
        },
        "osdi:donations": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/donations"
        },
        "curies": [
          {
            "name": "osdi",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          },
          {
            "name": "action_network",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          }
        ]
      }
    },
    "osdi:organizer": {
      "given_name": "John",
      "family_name": "Doe",
      "identifiers": [
        "action_network:c945d6fe-929e-11e3-a2e9-12313d316c29"
      ],
      "created_at": "2014-03-18T22:17:36Z",
	  "modified_at": "2014-03-19T14:07:41Z",
	  "originating_system": "Action Network",
      "email_addresses": [
        {
          "primary": true,
          "address": "jdoe@mail.com"
        }
      ],
      "postal_addresses": [
        {
          "primary": true,
          "address_lines": [
            "1600 Pennsylvania Ave"
          ],
          "locality": "Washington",
          "region": "DC",
          "postal_code": "20009",
          "country": "US",
          "language": "en",
          "location": {
            "latitude": 32.345,
            "longitude": -73.0729,
            "accuracy": "Approximate"
          }
        }
      ],
      "_links": {
        "self": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
        },
        "osdi:question_answers": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/question_answers"
        },
        "osdi:attendance": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/attendance"
        },
        "osdi:signatures": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/signatures"
        },
        "osdi:submissions": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/submissions"
        },
        "osdi:donations": {
          "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29/donations"
        },
        "curies": [
          {
            "name": "osdi",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          },
          {
            "name": "action_network",
            "href": "https://actionnetwork.org/docs/v1/{rel}",
            "templated": true
          }
        ]
      }
    }
  },
  "location": {
    "region": "",
    "country": "US",
    "language": "en",
    "location": {
      "latitude": 39.7599977890005,
      "longitude": -98.4999989109997,
      "accuracy": "Approximate"
    }
  },
  "_links": {
    "self": {
      "href": "https://actionnetwork.org/api/v1/events/21789f03-0180-45d3-853c-91bd6fdc8c07"
    },
    "osdi:attendance": {
      "href": "https://actionnetwork.org/api/v1/events/21789f03-0180-45d3-853c-91bd6fdc8c07/attendance"
    },
    "osdi:organizer": {
      "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
    },
    "osdi:creator": {
      "href": "https://actionnetwork.org/api/v1/people/c945d6fe-929e-11e3-a2e9-12313d316c29"
    },
    "action_network:embed": {
      "href": "https://actionnetwork.org/api/v1/events/21789f03-0180-45d3-853c-91bd6fdc8c07/embed"
    },
    "curies": [
      {
        "name": "osdi",
        "href": "https://actionnetwork.org/docs/v1/{rel}",
        "templated": true
      },
      {
        "name": "action_network",
        "href": "https://actionnetwork.org/docs/v1/{rel}",
        "templated": true
      }
    ]
  }
}
					

The above example added a new identifier to the event, changed the summary, and added a description.

Editing of certain fields via PUT is not allowed, and is noted in the field names table above. For example, you can't change the total_accepted count -- that is a system generated number reflecting a count of the underlying attendance collection. And you can't change a creator of an event. Invalid entries will be ignored.

Back To Top ↑

Scenario: Deleting an event (DELETE)

Deleting events is not allowed via the API. DELETE requests will return an error.

Back To Top ↑