Manage Development

Einstein Vision and Einstein Language include REST-based APIs to help you quickly build natural language processing into your apps. These APIs have a few key differences from other Salesforce APIs, like the REST API or the Chatter REST API.

  • The API endpoints are outside of your Salesforce app. For example, the Salesforce REST API endpoint to get an account might look like:<accountId>

The Einstein Vision API endpoint to get a dataset might look like:<datasetId>

  • Einstein Language uses OAuth 2.0 JWT bearer token flow for authorization. This authorization method is different from the authorization methods you can use with the Salesforce REST APIs, which are OAuth 2.0 web server flow, user-agent flow, or username-password flow.

Each Einstein API call requires a valid access token. You programmatically handle getting an access token by using your key or by generating a refresh token with your key to get an access token. When you use the Einstein Vision or Language APIs, calls to get a token are made to the endpoint:

  • When you customize the Salesforce app, you can use a sandbox environment, which is typically a copy of your production org, to test your changes. Because the Einstein Vision and Language APIs are outside of Salesforce, you define your own testing and deployment environments.

For example, you could have some test models that you create using an account for testing. Then when you decide one of those models is ready for production, you can create that dataset and model using your production account.