How do I create a Facebook event to have a specific time and time zone which does not change for individual users via the Graph API?

I am using the Facebook Graph API to publish events to a Fan Page. Our events are in-person events; therefore, we would like for the events to be published in the location's time zone so that when any Facebook user sees the event; it is listed in the event location's local time and the time zone is displayed if the user is not a part of that time zone. (Basically not have the precise time zone feature; where the event time is adjusted to display in the user's time zone). I am able create an event manually in Facebook which has the time zone set and the time is always displayed in that local time zone. Example of how the manually created event is displayed to a user which is not in the event location's time zone

But, I don't see any documentation on how to accomplish that behavior with the Graph API. I am hoping someone can point me in the right direction to accomplish this behavior?

Answers


You can set start_time for an action when publishing to the Graph API.

Then, you can use the following date format template:

yyyy-MM-dd'T'HH:mm:ss-03

where the date should be UTC and "-03" is the time zone where the event is generated (Buenos Aires in my case). This way, Facebook will show the date to the current time zone of the user.

Here's part of the documentation about this:

Represents a temporal value composed for a date (year, month and day) and an optional time component (hours, minutes).

Uses the ISO 8601 timestamp format, with the timezone defaulting to UTC. Expected format is YYYY-MM-DDThh:mm:ssZ, where Z is an offset from UTC to express a different time zone.

Also supports literals that conform to the following patterns:

%Y%m%dT%H%MZ
%Y%m%dT%H%M
%Y-%m-%dT%H:%MZ
%Y-%m-%dT%H:%M
%Y-%m-%d
%d-%m-%Y
%Y/%m/%d
%m/%d/%Y
%Y/%m/%dT%H:%MZ
%Y/%m/%dT%H:%M

See full documentation here: https://developers.facebook.com/docs/opengraph/creating-custom-stories#propertytypes


Need Your Help

Dynamically resize Simple Modal Depending on what is clicked

jquery simplemodal

I am fairly new to jQuery/JavaScript so I am having a few problems, hopefully you can point me on the right track.

Rails app and Android app connected to s3 bucket

android ruby-on-rails ruby amazon-web-services amazon-s3

I have a rails 4 app that uses carrierwave and Amazon s3 for image uploading. I also have a rest api built for my mobile application to talk to the database.