Eventbrite - Publish an event using using REST API - eventbrite

I am able to create an event using the REST API , but when I try to publish it using the API I am getting "There are errors with your arguments: event.tickets - MISSING" . Documentation says the tickets are required , But I don't see an option to pass the event.tickets in API ( I don't want to login to eventbrite and set the tickets after the event is created) . Thanks for your help.
To create an event ( Body parameters are given below )
https://www.eventbriteapi.com/v3/events/?token=mytokenid
"event" : {
"name": {
"html": "Here is an event name"
},
"start": {
"timezone": "America/Chicago",
"utc": "2018-08-03T00:00:00Z"
},
"end": {
"timezone": "America/Chicago",
"utc": "2018-08-03T03:00:00Z"
},
"currency": "USD",
"capacity":10
}
To publish the above event( This is one throwing the error)
https://www.eventbriteapi.com/v3/events/99999999(eventid)/publish/?token=mytoken

Got the solution for it , before publishing you have to call the tickets api to add the tickets ,
So here is the order to publish an event
1) Create event - https://www.eventbriteapi.com/v3/events/?token=mytoken
2) Add tickets to the above event - https://www.eventbriteapi.com/v3/events/aboveeventid/ticket_classes/?token=mytoken
3) Publish the above event - https://www.eventbriteapi.com/v3/events/aboveeventid/publish/?token=mytoken

Related

How to allow Microsoft Team attendees to bypass lobby programatically (Microsoft Graph)

I've created an event on a calendar using Calendar API which in turn in the response, it will give me the link to a Microsoft Team meeting link. This is an example data that I've send when creating the event. Also, I'm calling this API as an App not as a user, so basically all 3 attendees are not part of the AD users.
{
"attendees": [
{
"type": "required",
"emailAddress": {
"address": "attendee1#domain.com",
"name": "Attendee 1"
}
},
{
"type": "required",
"emailAddress": {
"address": "attendee2#domain.com",
"name": "Attendee 2"
}
},
{
"type": "required",
"emailAddress": {
"address": "attendee3#domain.com",
"name": "Attendee 3"
}
}
],
"end": {
"dateTime": "2020-11-13T17:32:39.636Z",
"timeZone": "UTC"
},
"start": {
"dateTime": "2020-11-11T16:32:39.636Z",
"timeZone": "UTC"
},
"subject": "My online meeting",
"isOnlineMeeting": true,
"body": {
"content": "Does this time work for you?",
"contentType": "HTML"
},
"onlineMeetingProvider": "teamsForBusiness",
"allowNewTimeProposals": false
}
In the response, I receive something like this:
...
"onlineMeeting": {
"joinUrl": "https://teams.microsoft.com/l/meetup-join/19%3ameeting_NzRmMDIwMWEtNGYyZS00MmNkLTk3NTAtOGxxxxkOGQ4ZDUx%40thread.v2/0?context=%7b%22Tid%22%3a%22b82fec80-bee7-401e-xxxx-8a312e0a62d1%22%2c%22Oid%22%3a%22112d58ba-xxxx-47ce-a1a8-3d0abebead18%22%7d"
}
...
My problem right now is none of the attendees can start the meeting. I wonder if there's a way programatically either when I'm creating the event or updating the online meeting, to enable the attendees to bypass the lobby and start the meeting.
According to your parameter, I think you use Calendar event api to create an online meeting.
I also tried this and found that the attendees needs permission to enter the meeting room while the creater can enter directly. I googled and found no graph api could modify this configuration. The only way to make every attendee join the meeting without permission is changing the meeting option as 'everyone can bypass the lobby'
By the way, admin role account can login the Microsoft teams admin center and automatically allow people in your organization bypass the lobby. This document tells the detail.
Actually, I used Fiddler to catch the changing option request and got a url like https://teams.microsoft.com/api/mt/amer/beta/meetings/v1/options/.... and an access token. I can use them to change the option successfully by sending a http post request. All seems the answer will appear but unfortunately after analizing the access token I found the api needs a permission https://api.spaces.skype.com which is not supported by Azure ad.

Calendar Access using Graph API

We have an application for the user to book/Edit/Cancel Room mailbox meeting from the portal.
So the user should be able to create a calendar event in the room mailbox and all participants should receive the meeting invite
Could you please advise What permission is required on Graph API other than "Calendars.ReadWrite"
According to the document about creating an online meeting, I tried to call the api and it worked with Calendars.ReadWrite permission, here's the detail.
Creating an Azure Ad app and add api permission
Get the access token , please note I just set ReadWrite as scope.
Call the api according to the document above and will get success response, you can open outlook and find meeting has created in calendar.
And here is my url and parameter:
Post:https://graph.microsoft.com/v1.0/me/events
Authorization:Bearer <access token>
Prefer:outlook.timezone="Pacific Standard Time"
Content-Type:application/json
body:{
"subject": "Prep for customer meeting",
"body": {
"contentType": "HTML",
"content": "Does this time work for you?"
},
"start": {
"dateTime": "2020-11-20T13:00:00",
"timeZone": "Pacific Standard Time"
},
"end": {
"dateTime": "2020-11-20T14:00:00",
"timeZone": "Pacific Standard Time"
},
"location":{
"displayName":"Cordova conference room"
},
"attendees": [
{
"emailAddress": {
"address":"AdeleV#contoso.OnMicrosoft.com",
"name": "Adele Vance"
},
"type": "required"
}
],
"allowNewTimeProposals": true,
"isOnlineMeeting": true,
"onlineMeetingProvider": "teamsForBusiness"
}

Try to call create event using graph api with isOnlineMeeting false for MS Teams

Getting isOnlineMeeting false while send isOnlineMeeting true whe we create the event using Graph API.
Could not reproduce the issue while creating a calendar event using Graph API. Kindly confirm if you are able to still reproduce it on your end.
Used the below query to create a new event:
POST https://graph.microsoft.com/v1.0/me/calendars/{id}/events
Request Body:
{
"subject": "Test Create Event",
"IsOnlineMeeting": "True",
"onlineMeetingProvider": "teamsForBusiness",
"body": {
"contentType": "HTML",
"content": "Does this time work for you?"
},
"start": {
"dateTime": "2020-12-18T12:00:00",
"timeZone": "Pacific Standard Time"
},
"end": {
"dateTime": "2020-12-18T14:00:00",
"timeZone": "Pacific Standard Time"
},
"location": {
"displayName": "Conf Room 1"
},
"attendees": [
{
"emailAddress": {
"address": "abc#mxxxxxxx.com",
"name": "Someone"
},
"type": "required"
}
]
}
Outcome: Was able to create a new calendar event with IsOnlineMeeting value set to true.
In case you are trying to update an existing calendar event, there is a known issue in that, where the isOnlineMeeting value keeps toggling between true and false for each update/patch request.
In that case, do not update the body in the request, and it should work.
There is an open bug for the update event issue.
Please refer -> Microsoft team link is not appearing for alternate update calendar events
Had the same problem, I add to add these permissions to the app I was using to create the meeting events:
TeamSettings.Read.All, TeamSettings.ReadWrite.All
As soon as I added them, isOnlineMeeting was correctly set to true, and onlineMeetingProvider was set to teamsForBusiness, as specified in the request.
onlineMeetingUrl is always null, but it's possible to get the meeting url from the "onlineMeeting.joinUrl" property, which is automatically populated by the API.

"Exception has been thrown by target of an invocation" for /findMeetingTimes request

I am developing a multi-tenant application with the Microsoft Graph API that makes use of the /findMeetingTimes endpoint. After many months of successful requests, on January 15th I started to see some errors coming through for a specific kind of request for some users.
The failing request is a POST to /findMeetingTimes for a single attendee who is the user on who's behalf I'm making the request. The same requests for more than a single attendee are still completing just fine, even if the user who authorized the request is included.
Nothing has changed in my request so this seems like it's either a change on the API side or a change in the user's configuration that's broken their ability to make requests of this type. Any insight on this error in this context would be helpful!
POST https://graph.microsoft.com/v1.0/me/findMeetingTimes
Request body:
{
"attendees": [
{
"emailAddress": {
"address": "[email of user who authorized the request]"
},
"type": "Required"
}
],
"meetingDuration": "PT30M",
"minimumAttendeePercentage": 100,
"maxCandidates": 400,
"timeConstraint": {
"timeslots": [
{
"start": {
"dateTime": [DateTime],
"timeZone": "UTC"
},
"end": {
"dateTime": [DateTime],
"timeZone": "UTC"
}
}
],
"activityDomain": "Unrestricted"
}
}
Returns (one specific example):
500: "Exception has been thrown by the target of an
invocation.", "innerError":{"request-id":"a039234e-f64e-489a-96cf
ff4f686a4389","date":"2018-01-18T01:51:49"}

SendGrid spec differences between versions of Event Notification Webhook

I have an existing rails3 application with SendGrid Service integration based on SMTP relay, and subscribed to Event Notification Webhooks.
I've got reminder email from Service, informing about impending change to SendGrid's service, and I need make some changes to match new version of Event Notification Webhooks v3.
Email I got contains instructions about How To Upgrade:
Review the documentation to understand how to consume this new version's events.
Implement changes on your side to handle the new in-formatting of event data.
Make changes on SendGrid's configuration page
I wounder, what changes now need I implement on my site? I read manual for v3, but there no information about specifications differences between old and new versions.
Previously, the SendGrid event webhook sent improper batched JSON, with documents seperated by line breaks:
{ "email": "john.doe#sendgrid.com", "timestamp": 1337197600, "smtp-id": "<4FB4041F.6080505#sendgrid.com>", "event": "processed" }
{ "email": "john.doe#sendgrid.com", "timestamp": 1337966815, "category": "newuser", "event": "click", "url": "http://sendgrid.com" }
{ "email": "john.doe#sendgrid.com", "timestamp": 1337969592, "smtp-id": "<20120525181309.C1A9B40405B3#Example-Mac.local>", "event": "processed" }
Today, with v3 it sends proper JSON as such:
[
{
"email": "john.doe#sendgrid.com",
"timestamp": 1337197600,
"smtp-id": "<4FB4041F.6080505#sendgrid.com>",
"event": "processed"
},
{
"email": "john.doe#sendgrid.com",
"timestamp": 1337966815,
"category": "newuser",
"event": "click",
"url": "http://sendgrid.com"
},
{
"email": "john.doe#sendgrid.com",
"timestamp": 1337969592,
"smtp-id": "<20120525181309.C1A9B40405B3#Example-Mac.local>",
"event": "processed"
}
]
If you'd previously been dealing with non-batched events you'll need to adjust your code so that it interprets an array, rather than just a single document, and then loops through said array. Put into code:
# This
consume_data(params)
# Becomes this
params.each { |doc|
consume_data(doc)
}

Resources