{"activeVersionTag":"latest","latestAvailableVersionTag":"latest","collection":{"info":{"_postman_id":"e8706ab1-3612-48b5-9a42-e6e4c94e4320","name":"Mashery API OAuth","description":"\n- [What is this?](#what-is-this)\n- [Why should I use it?](#why-should-i-use-it)\n- [How do I install and configure?](#how-do-i-install-and-configure)\n- [How do I execute the requests?](#how-do-i-execute-the-requests)\n- [Reference](#reference)\n    - [Getting an access token](#getting-an-access-token)\n    - [OAuth flows](#oauth-flows)\n    - [API Specification](#api-specification)\n\n**Confidentiality**\n\n© 2019 TIBCO Software Inc. All rights reserved.\n\nThe following is information of TIBCO Software Inc. Use, duplication, transmission, or republication for any purpose without the prior written consent of TIBCO is expressly prohibited.\n\n**Disclaimer**\n\nThis document (including, without limitation, any product roadmap or statement of direction data) illustrates the planned testing, release and availability dates for TIBCO products and services. This document is provided for informational purposes only and its contents are subject to change without notice. TIBCO makes no warranties, express or implied, in or relating to this document or any information in it, including, without limitation, that this document, or any information in it, is error-free or meets any conditions of merchantability or fitness for a particular purpose. This document may not be reproduced or transmitted in any form or by any means without our prior written permission.\nThe material provided is for informational purposes only, and should not be relied on in making a purchasing decision. The information is not a commitment, promise or legal obligation to deliver any material, code, or functionality. The development, release, and timing of any features or functionality described for our products remain at our sole discretion.\nIn this document TIBCO or its representatives may make forward-looking statements regarding future events, TIBCO’s future results or our future financial performance. These statements are based on management’s current expectations. Although we believe that the expectations reflected in the forward-looking statements contained in this document are reasonable, these expectations or any of the forward-looking statements could prove to be incorrect and actual results or financial performance could differ materially from those stated herein. TIBCO does not undertake to update any forward-looking statement that may be made from time to time or on its behalf.\n\n# What is this?\n\nThis collection runs all OAuth requests available in the [v3 Mashery API](https://developer.mashery.com/docs/read/mashery_api/30) and [v2 Mashery API](https://developer.mashery.com/docs/read/mashery_api/20).\n\nThe collection contains:\n\n* A set of [v3 Mashery API](https://developer.mashery.com/docs/read/mashery_api/30) requests to create OAuth token and resource endpoints.\n* A set of [v2 Mashery API](https://developer.mashery.com/docs/read/mashery_api/20) requests to manage OAuth tokens.\n* A set of [v3 Mashery API](https://developer.mashery.com/docs/read/mashery_api/30) requests to delete resources created by the collection.\n\n# Why should I use it?\n\nIt provides a convenient, portable way of using the Mashery OAuth APIs without doing any coding or reading much documentation. It's easy to make ad hoc requests and updates using the pre-built requests.\n\n# How do I install and configure?\n\n* You need a Mashery area, an id (username/password) and a v3 API key/secret. If you don't have these, then sign-up at https://developer.mashery.com/.\n* Download and install Postman from from https://www.getpostman.com/apps.\n* Open Postman, click on the 'Manage Environments' gear icon in the top right, select the 'Globals' button and add variables with values set to your credentials:\n  * 'v3 API domain' set to 'api.mashery.com'\n  * 'v3 API key'\n  * 'v3 API secret'\n  * 'v3 API username'\n  * 'v3 API password'\n  * 'area id' (the UUID)\n  * 'site id' (the id)\n* In a browser, go to https://documenter.getpostman.com/view/4885521/RzfnknBN and select 'Run in Postman' (button top right). This imports into Postman the Mashery API OAuth request collection.\n\nThat's it.\n\nNote: if you are using Mashery Local 5.1 or greater in untethered mode, then please consult the installation and configuration manual.\n\n# How do I execute the requests?\n\nExecute each v3 folder request in order up to and including 'Activate OAuth Package Key'. These create an OAuth enabled service with resource and token endpoints. They also create a member, package, plan and key to access that service.\n\nNow execute 'createAccessToken'. Depending on when you completed the previous requests, it can take up to 10 minutes before this can execute successfully. When 'createAccessToken' executes successfully, run 'Get OAuth Resource'. This uses the access token.\n\nAfter that, you can try 'revokeAccessToken' and then 'Get OAuth Resource' to show that the token is no longer valid.\n\nExecute the other requests in the v2 folder to try other OAuth functions.\n\nSome request responses pre-populate data for other requests. For example, executing 'Create OAuth Service' saves the service id, so if you then execute 'Create OAuth Token Endpoint' the service id in that request is already set.\n\nWhen you are finished, execute the three v3 folder delete requests in order. These remove the resources created by the collection.\n\n# Reference\n\n## Getting an access token\n\nTo execute any Mashery API request you need an access token so in Postman go to the Authentication folder and run the 'Get Token' request.\n\nNote: your 'v3 API key' and 'v3 API secret' are used in the Authorization header for the 'Get Token' request. The resulting access token is used in all other requests:\n\n```Authorization: Bearer xxxtokenxxx```\n\nThe token lasts one hour. You can now execute any other request. If you see a response 'Not Authorized', then you need a new token.\n\n## OAuth implementation guide\n\nhttps://community.tibco.com/wiki/tibco-mashery-oauth-20-implementation-guide\n\n## API Specification\n\nThe Mashery v3 API specification is available at:\n\nhttps://developer.mashery.com/docs/read/mashery_api/30\n\nThe Mashery v2 API specification is available at:\n\nhttps://developer.mashery.com/docs/read/mashery_api/20\n","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","isPublicCollection":false,"owner":"4885521","team":173382,"collectionId":"e8706ab1-3612-48b5-9a42-e6e4c94e4320","publishedId":"RzfnknBN","public":true,"publicUrl":"https://documenter-api.postman.tech/view/4885521/RzfnknBN","privateUrl":"https://go.postman.co/documentation/4885521-e8706ab1-3612-48b5-9a42-e6e4c94e4320","customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"documentationLayout":"classic-double-column","version":"8.11.6","publishDate":"2018-12-18T22:02:26.000Z","activeVersionTag":"latest","documentationTheme":"light","metaTags":{},"logos":{}},"statusCode":200},"environments":[],"user":{"authenticated":false,"permissions":{"publish":false}},"run":{"button":{"js":"https://run.pstmn.io/button.js","css":"https://run.pstmn.io/button.css"}},"web":"https://www.getpostman.com/","team":{"logo":"https://res.cloudinary.com/postman/image/upload/t_team_logo_pubdoc/v1/team/4896a25d7b836a72113558106de2cd21b285e8a489c8ac7127ce26eeeefcc575","favicon":""},"isEnvFetchError":false,"languages":"[{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"HttpClient\"},{\"key\":\"csharp\",\"label\":\"C#\",\"variant\":\"RestSharp\"},{\"key\":\"curl\",\"label\":\"cURL\",\"variant\":\"cURL\"},{\"key\":\"dart\",\"label\":\"Dart\",\"variant\":\"http\"},{\"key\":\"go\",\"label\":\"Go\",\"variant\":\"Native\"},{\"key\":\"http\",\"label\":\"HTTP\",\"variant\":\"HTTP\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"OkHttp\"},{\"key\":\"java\",\"label\":\"Java\",\"variant\":\"Unirest\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"Fetch\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"jQuery\"},{\"key\":\"javascript\",\"label\":\"JavaScript\",\"variant\":\"XHR\"},{\"key\":\"c\",\"label\":\"C\",\"variant\":\"libcurl\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Axios\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Native\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Request\"},{\"key\":\"nodejs\",\"label\":\"NodeJs\",\"variant\":\"Unirest\"},{\"key\":\"objective-c\",\"label\":\"Objective-C\",\"variant\":\"NSURLSession\"},{\"key\":\"ocaml\",\"label\":\"OCaml\",\"variant\":\"Cohttp\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"cURL\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"Guzzle\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"HTTP_Request2\"},{\"key\":\"php\",\"label\":\"PHP\",\"variant\":\"pecl_http\"},{\"key\":\"powershell\",\"label\":\"PowerShell\",\"variant\":\"RestMethod\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"http.client\"},{\"key\":\"python\",\"label\":\"Python\",\"variant\":\"Requests\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"httr\"},{\"key\":\"r\",\"label\":\"R\",\"variant\":\"RCurl\"},{\"key\":\"ruby\",\"label\":\"Ruby\",\"variant\":\"Net::HTTP\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"Httpie\"},{\"key\":\"shell\",\"label\":\"Shell\",\"variant\":\"wget\"},{\"key\":\"swift\",\"label\":\"Swift\",\"variant\":\"URLSession\"}]","languageSettings":[{"key":"csharp","label":"C#","variant":"HttpClient"},{"key":"csharp","label":"C#","variant":"RestSharp"},{"key":"curl","label":"cURL","variant":"cURL"},{"key":"dart","label":"Dart","variant":"http"},{"key":"go","label":"Go","variant":"Native"},{"key":"http","label":"HTTP","variant":"HTTP"},{"key":"java","label":"Java","variant":"OkHttp"},{"key":"java","label":"Java","variant":"Unirest"},{"key":"javascript","label":"JavaScript","variant":"Fetch"},{"key":"javascript","label":"JavaScript","variant":"jQuery"},{"key":"javascript","label":"JavaScript","variant":"XHR"},{"key":"c","label":"C","variant":"libcurl"},{"key":"nodejs","label":"NodeJs","variant":"Axios"},{"key":"nodejs","label":"NodeJs","variant":"Native"},{"key":"nodejs","label":"NodeJs","variant":"Request"},{"key":"nodejs","label":"NodeJs","variant":"Unirest"},{"key":"objective-c","label":"Objective-C","variant":"NSURLSession"},{"key":"ocaml","label":"OCaml","variant":"Cohttp"},{"key":"php","label":"PHP","variant":"cURL"},{"key":"php","label":"PHP","variant":"Guzzle"},{"key":"php","label":"PHP","variant":"HTTP_Request2"},{"key":"php","label":"PHP","variant":"pecl_http"},{"key":"powershell","label":"PowerShell","variant":"RestMethod"},{"key":"python","label":"Python","variant":"http.client"},{"key":"python","label":"Python","variant":"Requests"},{"key":"r","label":"R","variant":"httr"},{"key":"r","label":"R","variant":"RCurl"},{"key":"ruby","label":"Ruby","variant":"Net::HTTP"},{"key":"shell","label":"Shell","variant":"Httpie"},{"key":"shell","label":"Shell","variant":"wget"},{"key":"swift","label":"Swift","variant":"URLSession"}],"languageOptions":[{"label":"C# - HttpClient","value":"csharp - HttpClient - C#"},{"label":"C# - RestSharp","value":"csharp - RestSharp - C#"},{"label":"cURL - cURL","value":"curl - cURL - cURL"},{"label":"Dart - http","value":"dart - http - Dart"},{"label":"Go - Native","value":"go - Native - Go"},{"label":"HTTP - HTTP","value":"http - HTTP - HTTP"},{"label":"Java - OkHttp","value":"java - OkHttp - Java"},{"label":"Java - Unirest","value":"java - Unirest - Java"},{"label":"JavaScript - Fetch","value":"javascript - Fetch - JavaScript"},{"label":"JavaScript - jQuery","value":"javascript - jQuery - JavaScript"},{"label":"JavaScript - XHR","value":"javascript - XHR - JavaScript"},{"label":"C - libcurl","value":"c - libcurl - C"},{"label":"NodeJs - Axios","value":"nodejs - Axios - NodeJs"},{"label":"NodeJs - Native","value":"nodejs - Native - NodeJs"},{"label":"NodeJs - Request","value":"nodejs - Request - NodeJs"},{"label":"NodeJs - Unirest","value":"nodejs - Unirest - NodeJs"},{"label":"Objective-C - NSURLSession","value":"objective-c - NSURLSession - Objective-C"},{"label":"OCaml - Cohttp","value":"ocaml - Cohttp - OCaml"},{"label":"PHP - cURL","value":"php - cURL - PHP"},{"label":"PHP - Guzzle","value":"php - Guzzle - PHP"},{"label":"PHP - HTTP_Request2","value":"php - HTTP_Request2 - PHP"},{"label":"PHP - pecl_http","value":"php - pecl_http - PHP"},{"label":"PowerShell - RestMethod","value":"powershell - RestMethod - PowerShell"},{"label":"Python - http.client","value":"python - http.client - Python"},{"label":"Python - Requests","value":"python - Requests - Python"},{"label":"R - httr","value":"r - httr - R"},{"label":"R - RCurl","value":"r - RCurl - R"},{"label":"Ruby - Net::HTTP","value":"ruby - Net::HTTP - Ruby"},{"label":"Shell - Httpie","value":"shell - Httpie - Shell"},{"label":"Shell - wget","value":"shell - wget - Shell"},{"label":"Swift - URLSession","value":"swift - URLSession - Swift"}],"layoutOptions":[{"value":"classic-single-column","label":"Single Column"},{"value":"classic-double-column","label":"Double Column"}],"versionOptions":[],"environmentOptions":[{"value":"0","label":"No Environment"}],"canonicalUrl":"https://documenter.gw.postman.com/view/metadata/RzfnknBN"}