One of the classic example of a POST request is the Login page. When we send a POST request we generally intend to have some modification at the server such as updation, deletion, or addition. A POST request is a method that is used when we need to send some additional information inside the body of the request to the server. What is a POST Request?Ī POST is an HTTP Verb similar to a GET request, this specifies that a client is posting data on the given Endpoint. In this chapter, we will focus on another type of request method which is POST Request in Postman. From our Rest basics we already know what an HTTP Request and HTTP Response is.If you have not read these two tutorials yet, please do that before proceeding. NET, I have posted here:įor those who are interested in automating admin tasks and reporting, this might be useful.In the previous tutorials, we have learned about how to send a GET Request and we also learned about the Request Parameters. If you would like to see source code showing how to implement the API in. Hopefully the info here will get you started, and community members will add their tips and tricks. Look through the Postman docs for tutorials and advanced techniques: Postman Docs Search Google for video walk-throughs to provide additional details. This is basic info to help someone get started. If you are not familiar with JSON take a look at this W3Schools page for an overview: JSON is notation representing object data. Notice this time that PUT is selected in Postman.ĪPI results come back in JSON format. In this example, I am passing a parameter to publish/unpublish a course (which is useful in a script to publish all courses at the beginning of a semester). ![]() This might be useful, an API call to update a course: Notice in this screen shot that POST is selected. This is an example of a POST command to copy course content into another course:Ĭourses - Canvas LMS REST API Documentation You can see that GET has been selected as the type of API call being made, the authorization token has been provided, and the json results are displayed. In this case the API call is asking for the status of a content migration request. The following screen shot shows an example of making a GET call to get the current status of an asynchronous job: Progress - Canvas LMS REST API Documentation You will need to tell Postman what type of API call you are making, i.e.GET, POST, PUT, whatever HTTP verb is associated with the API call. This screen shot also shows an example of the syntax to get a list of enrollments for a specific course, which you might want to use to test your token. Enter the value "Authorization" for the key.The following screen shot illustrates how to use the Headers to submit your token. To make an API call you will need to use your developer token to authenticate. ![]() Postman provides documentation on installing the Chrome web app and the native app here: Personally I have not downloaded the native app yet, and have exclusively used the Chrome web app so far. ![]() Postman also has a native app that you can install directly, which can be downloaded here: To find the Postman web app and install it, search the Web Store for "Postman" Install and manage apps - Chrome Web Store Help If you haven't installed an app in Chrome before take a look at this article: Postman is easily accessible in Chrome through the Web Store. My hope is that folks who are experienced with the tool can add to this information and further help new users get up to speed. But, searching the Community I have not found any posts specifically about this tool and feel it might be worth talking about for those looking for a starting point. I have seen questions in the community about the API, and have see Postman mentioned many times. This information is really geared towards users who are trying to get started with the API.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |