cancel
Showing results for 
Search instead for 
Did you mean: 

QAComplete 10.2 Rest API Authorization

New Contributor

QAComplete 10.2 Rest API Authorization

Hi,

I tried accessing QAcomplete Releases list using Rest API's, but I couldn't get authorization passed. 

I found this on the website:

 

"To call any QAComplete API operation, authentication is needed. To log in to QAComplete, you send your user name (login) and password to QAComplete in your first request (see below). QAComplete will respond with a security token. In your

subsequent requests, you will need to specify your login and the security token"

 

I tried using my login and password for the authorization, which I couldn't pass through. But above statement mentions that I need to have security token to have. How do I get the Security token in QAcomplete ? Please let me know. Thanks !

9 REPLIES
Occasional Contributor

Re: QAComplete 10.2 Rest API Authorization

I was able to connect to QAComplete for creating test folder by selecting basic Auth as a the Authorization tab. I have used Postman for this.

 

Hope this helped. Let me know if you have any other question regarding this

New Contributor

Re: QAComplete 10.2 Rest API Authorization

Hi - I have used postman for a Get request, but fails at the authorization.

Is there any place where we need to enable to the Rest access in QAcomplete? Please let me know.

 

Frequent Contributor

Re: QAComplete 10.2 Rest API Authorization

Would you please provide an example of sending a request from prostman. thanks

Occasional Contributor

Re: QAComplete 10.2 Rest API Authorization

1. Create a new POST operation.

2. Authorization type should be Basic auth. Provide the User Id and password. 

3. Parameterize the Environment Variables in the Endpoints if required, Example

{{url}}/api/v2/projects/{{projectid}}/Tests/Folders.

 

Go to Postman Runner and point to  your test case sheet from where the data needs to be extracted.

 

Try with couple of scenarios and you can see more options after this.

Frequent Contributor

Re: QAComplete 10.2 Rest API Authorization

i'm trying a create a defect and getting an error. Server Error in '/rest-api' Application

https://qacomplete.smartbear.com/rest-api/service/api/v2/projects/{ProjectId}/tests/defects

Occasional Contributor

Re: QAComplete 10.2 Rest API Authorization

Can you explian what you are task are you trying to perform using the API.

 

1. Creating Defects

2. Created Test cases 

3. Updating the status of the test instances 

Frequent Contributor

Re: QAComplete 10.2 Rest API Authorization

Hi, 

i'm trying to create defect. 

ex:body

{
"Title": "Error Finding Locations",
"Status": "New",
"Description": "System is throwing an error searching for the location ."
}

 

Occasional Contributor

Re: QAComplete 10.2 Rest API Authorization

Follow the below steps to setup the script in Postman and you should be able to create a defect using the API's

 

Step 1
URI - https://qacomplete.smartbear.com/rest-api/service/api/v1/projects/{ProjectId}/defects

Replace project id. You can find the project Id in the QAComplete URL

 

Step 2 - Authorization Tab
Authorization
Select Type - Basic Auth
Enter your QAComplete - Username & Password

 

Step 3 - Header Tab
Key - Content-Type
Value - application/json

 

Step 4 - Body Tab
Select option raw (Radio button)
Set the Request Payload in the Body tab
{
"Title": "SAMPLE TITLE 1",
"Status": "In Progress",
"Description": "Test Desc"
}

 

Step 5
Save and click on Send button, Defects will be created in QAComplete.

Frequent Contributor

Re: QAComplete 10.2 Rest API Authorization

i did everything as described, and same thing , getting 404 status. i'm able to get response from the tests folder. but unable to post defects,,, 

2018 NEWS