GithubHelp home page GithubHelp logo

isabella232 / microsoft-graph-explorer-api Goto Github PK

View Code? Open in Web Editor NEW

This project forked from microsoftgraph/microsoft-graph-devx-api

0.0 0.0 0.0 3.97 MB

Services API for Graph Explorer

License: MIT License

C# 99.25% Dockerfile 0.12% HTML 0.63%

microsoft-graph-explorer-api's Introduction

microsoft-graph-explorer-api

Graph Explorer API Endpoints

The Graph Explorer API is a RESTful API that exposes resources that are used by Microsoft Graph docs, Graph Explorer, Graph samples workload teams and are managed by the Graph PM team. Below is a brief description of each of the various endpoints under the Graph Explorer API.

1. Snippet Generator

This endpoint provides a means of getting a code snippet on how to perform a certain action on Microsoft Graph.

The API takes in the HTTP request message to be sent to Microsoft Graph and the programming language to return a response with the code snippet string.

The API currently supports the generation of snippets to the Microsoft Graph API in the following languages

  • C#
  • Javascript
  • Objective C
  • Java

Example Snippets

2. Samples

  • This endpoint serves up the list of sample queries and the means of adding, updating or deleting them. Members from the workload teams are able to add, update or delete the sample queries with the right permissions. The sample queries are also queryable by their category name, human name or tip.
  • An authorized user will need to be granted permission to be able to do any POST, PUT or DELETE operations on any sample query category. The Graph PMs have the authority to grant users permissions for the write, update, delete operations of each of the sample queries categories.

3. Permissions

This endpoint serves up a list of scopes and their information, ordered from the least to most permissive, when given a request url, an HTTP verb/method (GET, PUT, POST, DELETE) and the scope type (DelegatedWork, DelegatedPersonal or Application). Graph Explorer uses this endpoint to render the list of sample queries on its page.

4. Samples Admin

This is the administrative endpoint of the API that is used by authorized Graph PMs to assign permissions to workload team members for them to be able to perform write, update and delete operations on the sample queries.

How to use the endpoints

This API makes use of Swagger UI to expose its resources for end user consumption. Some protected resources can be called only after a successful authentication with Azure AD.

1. Authorize on Swagger UI

Calling the secured resources of the API requires authentication with Azure AD.

  1. Navigate to: https://graphexplorerapi.azurewebsites.net/swagger/index.html and click on the Authorize button. Authorize start
  2. In the dialog window that opens, select the scope checkbox.
  3. Choose Authorize. Authorize with client id and scope
  4. You will be redirected to a separate window where you will be asked to log in with your Microsoft account and asked to grant permission to Graph Explorer API Swagger UI. Choose Accept.
  5. Upon successful authorization, you will be redirected back to the Swagger UI window and you will see the below dialog. Choose Close. Authorization success

3. Call the endpoints

  • Click the Try it out button to make a call to a resource. Try it out

  • For POST and PUT operations, you will be provided with an editable request body template in the Request body window which you can update with the details of the data you wish to send in your request. The content-type is JSON. Request body

  • Click on the Execute button to make the request. Execute request

  • Request responses will be displayed in the Responses window. Request response

License

Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT license.

microsoft-graph-explorer-api's People

Contributors

andrueastman avatar baywet avatar d-titusgicheru avatar darrelmiller avatar ddyett avatar irvinesunday avatar maggiekimani1 avatar michaelmainer avatar shjokie avatar thewahome avatar zengin avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.