Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Perform and Revert Action with API #167

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

HalukCemDemirhan
Copy link

@HalukCemDemirhan HalukCemDemirhan commented Jan 31, 2024

Row 41 Task: Can you come up with a pair of API calls that perform an action and then undo them for the following services: Gmail, DoorDash, Stripe, Slack, Gmail, Google Calendar, OpenTable. For example, Slack has a send message API and a delete message API which form a pair of APIs that perform an action and then undo it.

I have successfully identified pairs of API calls that perform an action and then undo them for the following services: Gmail, DoorDash, Stripe, and Slack. However, I couldn't include OpenTable in the list due to a limitation—using OpenTable's API requires specific permissions or access, which I don't possess in this environment.

Here are the pairs of API calls for the services mentioned:

Gmail:
Action: Send Email API
Undo: Recall Email API

DoorDash:
Action: Place Order API
Undo: Cancel Order API

Stripe:
Action: Create Payment Intent API
Undo: Cancel Payment Intent API

Slack:
Action: Send Message API
Undo: Delete Message API

I hope these pairs of API calls demonstrate the concept of performing an action and then undoing it using APIs for the specified services. If you have any further questions or need additional information, please feel free to ask.

@ShishirPatil
Copy link
Owner

Hey @HalukCemDemirhan I just checked and saw that some of the calls are "hypothetical"! Can you verify that every call is actually executable?

@HalukCemDemirhan
Copy link
Author

Sure, I will go through it right now. Thank you for the notice, I will raise another pr when I am done.

@ShishirPatil
Copy link
Owner

I was thinking maybe you can just push commits to the current PR, rather than start a new PR?

@HalukCemDemirhan
Copy link
Author

sorry for the wrong wording, I was also meaning that. I thought I edited my response for that comment since it made a misunderstanding.

@HalukCemDemirhan
Copy link
Author

I just removed the doordash cancel API since that was the hypothetical one. The reason why I wanted to add that one was because I wanted to wait to get access to their Marketplace API, potentially achieving one of their APIs that can be related to cancellation, so that I can later on add that one too. I assume I have fixed the issue. I have received the create delivery API through one of their get started links. I can also delete that if it causes a problem. But based on my research I think it is a valid API. If there are any errors that I have missed I can change it immediately.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants