Is it possible to create a term template using REST API?

Ali 15 Reputation points

Is it possible to create term templates in Purview using REST APIs?

Microsoft Purview
Microsoft Purview
A Microsoft data governance service that helps manage and govern on-premises, multicloud, and software-as-a-service data. Previously known as Azure Purview.
920 questions
{count} votes

2 answers

Sort by: Most helpful
  1. PRADEEPCHEEKATLA-MSFT 76,586 Reputation points Microsoft Employee

    - Thanks for the question and using MS Q&A platform.

    Yes, it is possible to create term templates in Microsoft Purview using REST APIs.

    To create a term template, you can use the "Create Term Template" REST API endpoint in the Purview API. Here's an example of how to create a term template using the REST API:

    1. Get an OAuth2 access token: To call the Purview API, you need to obtain an access token using OAuth2 authentication. You can obtain an access token by sending a request to the Azure Active Directory token endpoint.
    2. Create a term template JSON payload: You need to create a JSON payload that defines the properties of the term template you want to create. Here's an example of a JSON payload for a term template:
      "name": "MyTermTemplate",
      "description": "This is a sample term template.",
      "terms": [
          "name": "Term1",
          "description": "This is the first term.",
          "isSystem": false
          "name": "Term2",
          "description": "This is the second term.",
          "isSystem": false
    1. Call the "Create Term Template" API endpoint: You can use the HTTP POST method to call the "Create Term Template" API endpoint and pass the JSON payload in the request body. Here's an example of the API endpoint URL:


    Note that you need to replace "{accountname}" with the name of your Purview account.

    1. Verify the response: If the term template is created successfully, the API endpoint returns a response with the status code 201 (Created) and the JSON payload of the created term template.

    For more details, refer to Microsoft Purview - REST API.

    Hope this helps. Do let us know if you any further queries.

    If this answers your query, do click Accept Answer and Yes for was this answer helpful. And, if you have any further query do let us know.

  2. Cayir Aydar, Aysegul 0 Reputation points

    @Ali could you solve your problem? I try to do same thing.

    0 comments No comments