How to get API when a project is created?

Updated on March 25, 2020 06:19AM by Admin

API(Application Program Interface) is a tool used to create communication between two software. Using this, you can deliver your request to an application and receive a response effectively without accessing the Application.

  • To get the API for creating a project, go to Settings → API → Create. You can see the Create Project API page in the right pane.
Settings

  • Here, you can gain the API information needed to create a Project. The different attributes present are mentioned in detail below.

API URL

This is the URL to create a project using API.

https://api2.apptivo.com/app/dao/v6/projects?a=save&projectInformation={ ... }&apiKey=&accessKey=;

ProjectInformation

This has the data related to the attributes whose values will be added when a Project is created.

{

      "name": "name",

      "description": "description",

      "startDate": "startDate",

      "endDate": "endDate",

      "projectName": "projectName",

      "projectId": "projectId",

      "statusMeaning": "statusMeaning",

      "statusId": "statusId",

      "priorityMeaning": "priorityMeaning",

      "priorityId": "priorityId",

      "priority": "priority",

      "projectManagerId": "projectManagerId",

      "projectManagerName": "projectManagerName",

      "customerName": "customerName",

      "customerId": "customerId",

      "labels": [

          {

              "LabelName": "LabelName",

              "LabelId": "LabelID"

          }

      ],

      "assigneeObjectId": "assigneeObjectId",

      "projectPeople": [

          {

              "employeeId": "employeeId",

              "employeeName": "employeeName",

              "emailId": "emailId"

          }

      ],

      "billingMethodId": "billingMethodId",

      "billingMethodName": "billingMethodName",

      "currencyCode": "currencyCode",

      "estimatedCostCurrencyCode": "estimatedCostCurrencyCode",

      "projectFeeCurrencyCode": "projectFeeCurrencyCode",

      "estimatedEffort": "estimatedEffort",

      "estimatedCost": "estimatedCost",

      "projectFee": "projectFee",

      "isActive": "isActive",

      "addresses": [ ],

     "customAttributes": [

         {

              "id": reference_1583304512211_525_924831583304512211_78,

              "customAttributeId": reference_1583304512211_525_924831583304512211_78,

              "customAttributeName": reference_1583304512211_525_924831583304512211_78,

              "customAttributeType": reference,

              "customAttributeValue": 

          },

          {

              "id": referenceField_1583304512211_653_1144971583304512211_357,

              "customAttributeId": referenceField_1583304512211_653_1144971583304512211_357,

              "customAttributeName": referenceField_1583304512211_653_1144971583304512211_357,

              "customAttributeType": referenceField,

              "customAttributeValue": 

          }

    ]

}


The mandatory fields required to create a project are mentioned below:

  • startDate
  • projectManagerId
  • projectManagerName
  • currency
  • billingMethodId
  • billingMethodName
  • statusMeaning
  • statusId
  • priorityId
  • priorityMeaning

Description of Mandatory Attributes

  • name

This is a text field which indicates the name of the Project.

  • startDate

This is a date field denoting the start date of the Project.

  • projectManagerId

You can use this attribute to select any employee. This is the ID of the Project Manager.

  • projectManagerName

This attribute is used to add the name of the Project manager.

  • currency

Here, you can add the currency format of the project. By default, it will display the firm country currency code. This is a search and select field. If you want to create a project with multicurrency, you need to configure the multi-currency from the User Menu → Business Settings page → Currencies.

  • billingMethodId

This is the ID of the Billing Method.

  • billingMethodName

You can use this field to add the Name of the Billing Method. In projects, Billing is carried out using four methods. They are,

  • Project Flat Fee
  • Milestone Billing
  • Time & Expenses
  • Non- Billable
  • statusId

This indicates the ID of the project status.

  • statusMeaning

This attribute is used to add the status of the Project. By default, we will display 6 project statuses. They are,

  • Awaiting Kickoff
  • On Track
  • Behind Schedule
  • In Trouble
  • On Hold
  • Completed

You can also create your own project status or change the name of the status by navigating to Projects → Settings → Projects → Statuses → Projects.

  • priorityId

This is the Id of project priority.

  • priorityMeaning

Here, you can add the priority of the project. By default, we have three priorities. They are,

  • High
  • Medium
  • Low

You can also create a new priority ord edit the existing priority by moving to Settings → Projects → Priorities.

Description of Additional Attributes

Projects App has the following additional attributes. It is not necessary to add the values for these attributes.

  • description

You can add a detailed description of the project in this attribute.

  • endDate

You can use this attribute to record the end date of the project.

  • customerName

You can enter the customer name here.

  • customerId

This is the customer ID of the project.

  • labels

Labels denote the tags created from Settings → General → Tags.

  • projectpeople

projectpeople is nothing but who are all the employees going to work on that project.

  • estimatedEffort

The estimated effort needed for the completion of the Project is recorded here.

  • estimatedCost

You can use this to enter the estimated cost for the project.

  • projectFee

projectFee is used to record the exact project fee for the project.

  • isActive

This is based on project status. If the project status is enabled in the Settings → Projects → Statuses → project statuses, it will be “Y” otherwise “N”.

  • customAttributes

To create records with custom attributes, you have to send this param.

  • Addresses

This is the custom address field used to add the email address.

  • emailAddresses

This is the custom email address field where you can enter the email address.

  • phoneNumbers

This is a custom phone number field where you can add the phone number.

Creating a Project

Once the necessary data is available. Develop the necessary coding and run it in your browser with changed values for the attributes.

For Instance: This is the API used to create a Project in Caroline’s business.

Projects Create API
  • Here, you can see the API URL and ProjectInformation are combined to create an API for project creation. You just have to add values for the attributes.
  • Now, copy the API and run it in your browser. You can see it is loaded successfully.
Load Success

  • When you navigate to your Projects App of Apptivo, you can see a record is created with the values mentioned in the API.
Project Created