I follow this URL as below and try to test Content Server REST API, but I fail (using http://localhost/OTCS/cs/api/v1/ ).
Anyone met this before, does REST API need to extra installation? or set up?
https://developer.opentext.com/webaccess/#url=/awd/resources/articles/6102/content+server+rest+api++quick+start+guide
You have to use absolute URLs to resources, which you connect to. ".../api/v1" is only a part of the path. ".../api/v1/auth" would make the path complete. Use Postman or Advanced REST Client to test CS REST API resources, as it is recommended in the Content Server REST API - Quick Start Guide. The Swagger documentation does not connect to your local server.
Is there a sample code in C#.NET somewhere that demonstrate the use the Rest APIs? I have used CS Web Services but have never written code to access Rest APIs. Our requirement here is to migrate a bunch of users in OTDS from CS 16.0 to 16.2...and looks like the recommended way is to do it using Rest API & not Web Services.
Any pointers will be appreciated!
You can look up any general tutorial for making a REST CALL from C#. You will be interested in WebClient or HttpWebRequest objects. If you have the .NET 4.5 or newer, you can see HttpClient too.
Once you make yourself familiar with the general concept of making raw HTTP requests, you will use the CS REST API Swagger documentation to learn about the available resources: https://knowledge.opentext.com/go/67789539.