Skip to main content

createuser.do (Deprecated)

The createuser.do call creates a new user account. You must be logged into an API service account to create a user account with this call. To create an API service account, you must use the Veracode Platform or the Identity REST API.

Before using this API, Veracode strongly recommends that you read API usage and access guidelines. Ensure you access the APIs with the domain for your region.

REST API equivalent

The REST API equivalent of this call is a POST to /api/authn/v2/users using the Identity API. Veracode strongly recommends that you use the REST API for this action. For new integrations, always use the REST APIs.

Resource URL

https://analysiscenter.veracode.com/api/3.0/createuser.do

Permissions

An API service account requires the Admin API role to use this call. A user account requires the Administrator role to use this call.

Parameters

NameTypeDescription
first_name
Required
StringFirst name of the user.
last_name
Required
StringLast name of the user.
email_address
Required
StringEmail address of the user.
custom_id
Required
StringRequired for SAML users only. The SAML Subject field value from the user account.
roles
Required
String (case-sensitive)Comma-separated list of valid, user account roles:
  • Administrator
  • Creator
  • Delete Scans
  • eLearning
  • Executive
  • Greenlight IDE User
  • Mitigation Approver
  • Policy Administrator
  • Reviewer
  • Sandbox Administrator
  • Sandbox User
  • Security Insights
  • Security Lead
  • Submitter
  • Vendor Manager
You cannot pass any of the API roles for API service accounts. If you specify the Creator, Security Lead, or Submitter role, Veracode automatically applies the Any Scan permission to the scans. You can apply scan permissions to these types of scans: Static Analysis, Dynamic Analysis, Discovery, manual, and Dynamic Analysis.
is_saml_userBooleanYou can only update this parameter if your account is SAML-enabled.
login_enabledBooleanSpecifies whether the user can log in to the account.
phoneStringContact phone number for the user.
requires_tokenBooleanSpecifies whether a user must provide a two-factor authentication token.
teamsString (case-sensitive)Comma-separated list of team names. For a user with team membership restrictions, ensure all specified teams are on the Team Memberships list for that user.
titleStringUser title or position.

HTTPie example

Examples use the HTTPie command-line tool.

http --auth-type=veracode_hmac -o newuserinfo.xml "https://analysiscenter.veracode.com/api/3.0/createuser.do" "first_name==Regina" "last_name==Monarch" "[email protected]" "teams==Demo Team" "roles==Creator,Submitter,eLearning"

HTTPie results

The createuser.do call returns the userinfo XML document, which references the userinfo.xsd schema file. You can use the XSD schema file to validate the XML data.

<?xml version="1.0" encoding="UTF-8"?>

<userinfo xmlns:xsi="http&#x3a;&#x2f;&#x2f;www.w3.org&#x2f;2001&#x2f;XMLSchema-instance"
xmlns="https&#x3a;&#x2f;&#x2f;analysiscenter.veracode.com&#x2f;schema&#x2f;userinfo&#x2f;3.0"
xsi:schemaLocation="https&#x3a;&#x2f;&#x2f;analysiscenter.veracode.com&#x2f;schema&#x2f;userinfo&#x2f;3.0
https&#x3a;&#x2f;&#x2f;analysiscenter.veracode.com&#x2f;resource&#x2f;3.0&#x2f;userinfo.xsd" userinfo_version="3.0"
username="rmonarch&#x40;example.com">
<login_account first_name="Regina" last_name="Monarch" login_account_type="user" email_address="rmonarch&#x40;example.com"
login_enabled="true" requires_token="false" teams="Demo Team" roles="Creator,eLearning,Submitter,Any Scan"
is_elearning_manager="false" elearning_manager="No Manager" elearning_track="No Track Assigned"
elearning_curriculum="No Curriculum Assigned" keep_elearning_active="false"/>
</userinfo>

API wrapper examples: Create multiple users

Using the inputfilepath parameter of the Java or C# API wrapper and a CSV file, you can make multiple calls to createuser.do.

The first column of the CSV contains the action (createuser) and each subsequent column represents a parameter. The first row of the CSV file contains the included parameter names. There must be a column for each required parameter. Columns for optional parameters may be omitted.

CSV data:

actionfirstnamelastnameemailaddressrolesteams
createuserWayneShorter[email protected]Security LeadRelease Team
createuserTonyWilliams[email protected]"Creator,Submitter"Demo Team
createuserCarlaBley[email protected]Security Insights 

CSV file:

action,firstname,lastname,emailaddress,roles,teams
createuser,Wayne,Shorter,[email protected],Security Lead,Release Team
createuser,Tony,Williams,[email protected],"Creator,Submitter",Demo Team
createuser,Carla,Bley,[email protected],Security Insights

Java example:

java -jar vosp-api-wrapper-java{version}.jar -vid <Veracode API ID> -vkey <Veracode API Key> -action createuser -inputfilepath c:\javawrappers\newusers.csv

C# example:

VeracodeC#API -vid <Veracode API ID> -vkey <Veracode API key> -action createuser -inputfilepath c:\csharpwrappers\newusers.csv

API wrapper results

The createuser.do call returns the userinfo XML document, which references the userinfo.xsd schema file. You can use the XSD schema file to validate the XML data.

The API wrapper returns three XML documents:

<?xml version="1.0" encoding="utf-8"?>

<userinfo xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="https://analysiscenter.veracode.com/schema/userinfo/3.0"
xsi:schemaLocation="https://analysiscenter.veracode.com/schema/userinfo/3.0
https://analysiscenter.veracode.com/resource/3.0/userinfo.xsd" userinfo_version="3.0"
username="[email protected]">
<login_account first_name="Wayne" last_name="Shorter" login_account_type="user"
email_address="[email protected]" login_enabled="true" requires_token="false"
teams="Release Team" roles="Security Lead,Any Scan" />
</userinfo>
<?xml version="1.0" encoding="utf-8"?>

<userinfo xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="https://analysiscenter.veracode.com/schema/userinfo/3.0"
xsi:schemaLocation="https://analysiscenter.veracode.com/schema/userinfo/3.0
https://analysiscenter.veracode.com/resource/3.0/userinfo.xsd" userinfo_version="3.0"
username="[email protected]">
<login_account first_name="Tony" last_name="Williams" login_account_type="user"
email_address="[email protected]" login_enabled="true" requires_token="false"
teams="Demo Team" roles="Creator,Submitter,Any Scan" />
</userinfo>
<?xml version="1.0" encoding="utf-8"?>

<userinfo xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="https://analysiscenter.veracode.com/schema/userinfo/3.0"
xsi:schemaLocation="https://analysiscenter.veracode.com/schema/userinfo/3.0
https://analysiscenter.veracode.com/resource/3.0/userinfo.xsd" userinfo_version="3.0"
username="[email protected]">
<login_account first_name="Carla" last_name="Bley" login_account_type="user"
email_address="[email protected]" login_enabled="true" requires_token="false"
teams="" roles="Security Insights" />
</userinfo>