Route: https://api.cytrix.io/ProjectTargets
This feature will allow you to fetch scans associated with a particular project.
Roles Required: Admin and User. Private User can only fetch Targets he initiated from a project he created.
Request Syntax
{
"apiKey": "string",
"projectId": int,
"projectName": "String",
"desc": True/False,
"sort": "string"
}
Request Parameters
Parameters being used in the Request
Parameter Name :
apiKey
Parameter Usage and Options :
Your CYTRIX given API Key.
How do I get it ? :
Located in the “Profile” section.
Note : by default, the “API Status” is enabled, unless, the Admin has disabled it in the “Server Settings” section.
Type :
String
Is it Optional ? :
No.
Parameter Name :
projectName
Parameter Usage and Options :
This parameter will allow you to set your Project Name that will be used to tag your targets while scanning with CYTRIX.
How do I get it ? :
There’s a table, containing all the projects you created in the “Projects” section.
Type :
String
Is it Optional ? :
No
Parameter Name :
projectId
Parameter Usage and Options :
An ID for the project requested.
How do I get it ? :
I recommend using the “DetailsProject” or “GetProjects” functions.
Type :
Integer
Is it Optional ? :
No
Parameter Name :
sort
Parameter Usage and Options :
allows you to sort your imported projects by id\name.
Type :
String
Is it Optional ? :
Yes.
Parameter Name :
desc
Parameter Usage and Options :
In case you want to fetch the Targets in descending order.
Value :
True/False
Type :
Boolean
Is it Optional ? :
No – if you enable sort.
Successful Response
{
"Error": 0,
"Function": "ProjectTargets",
"Data": [
"String",
"String",
"String",
"String",
"String",
"String",
"String",
"String"
]
}
Errors and their Possible Causes
{ “Error”: 2, “Function”: “ProjectTargets”, “Data”: “project not exist”} – means that the requested project doesn’t exist.
For more information, please refer to the General Errors section.