page_type: sample
languages:
- csharp
- html
- java
- javascript
- swift
- python
products:
-
azure
description: "This repo provides code samples for cognitive services APIs."
urlFragment: cognitive-services-REST-api-samples
Samples for REST APIs in Cognitive Services
This repo provides code samples for Azure Cognitive Services APIs. There are sections for Language, Search, and Vision, using various progamming languages. Note that these are just simple wrappers to the APIs. For SDKs and SDK samples there are separate repos (see below for references).
Cognitive Services introduction: https://azure.microsoft.com/en-us/services/cognitive-services/
Cognitive Services docs: https://docs.microsoft.com/en-us/azure/cognitive-services/
Getting Started
These REST samples require some steps:
- Copy the sample into your favorite IDE or text editor.
- Get a subscription key and endpoint from your API service (for example, Computer Vision or Bing Search, etc.) If you have not created the Azure service you need, go here to get a free (or paid) account: https://azure.microsoft.com/en-us/free/?WT.mc_id=A261C142F
- Add your key and endpoint to your environment variables with the naming as shown in the code sample.
- Install libraries if needed (instructions on the ones needed are in the sample).
- Compile and run the sample through your IDE or the command line.
- (Optional) You may want to download the whole repo first:
git clone https://github.com/Azure-Samples/cognitive-services-REST-api-samples
Resources
SDK Samples
Service-specific SDK Samples