Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Date fields in the Bamboo REST API

Chandan Datta February 25, 2020

What is definition of the date fields in the REST API link, because the one returned by the API for example the startedDate is not the same as in the XSD (xs:dateTime) 

Screen Shot 2020-02-26 at 2.45.33 PM.jpg


1 answer

1 accepted

0 votes
Answer accepted
Elias Zeidan (they/them)
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
March 10, 2020

Hi Chattan,

Thank you for reaching out to the Atlassian Community!

I appreciate you calling out the discrepancy between the API documentation and the API results.

This REST API does not have an XML result, so the XSD would not be applicable here. That being said, however, the nodes with type="xs:dateTime" in the XSD for these endpoints (example below) are Unix timestamps in milliseconds.

<xs:complexType name="restDeploymentResult">
<xs:element name="deploymentVersion" type="restDeploymentVersion" minOccurs="0"/>
<xs:element name="deploymentVersionName" type="xs:string" minOccurs="0"/>
<xs:element name="id" type="xs:long"/>
<xs:element name="deploymentState" type="buildState" minOccurs="0"/>
<xs:element name="lifeCycleState" type="lifeCycleState" minOccurs="0"/>
<xs:element name="startedDate" type="xs:dateTime" minOccurs="0"/>
<xs:element name="queuedDate" type="xs:dateTime" minOccurs="0"/>
<xs:element name="executedDate" type="xs:dateTime" minOccurs="0"/>
<xs:element name="finishedDate" type="xs:dateTime" minOccurs="0"/>
<xs:element name="reasonSummary" type="xs:string" minOccurs="0"/>
<xs:element name="key" type="restDeploymentResultKey" minOccurs="0"/>
<xs:element name="agent" type="restBuildAgent" minOccurs="0"/>
<xs:element ref="operations" minOccurs="0"/>

<xs:complexType name="restDeploymentVersion">
<xs:element name="id" type="xs:long"/>
<xs:element name="name" type="xs:string" minOccurs="0"/>
<xs:element name="creationDate" type="xs:dateTime" minOccurs="0"/>
<xs:element name="creatorUserName" type="xs:string" minOccurs="0"/>
<xs:element name="items" type="restDeploymentVersionItem" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="versionStatus" type="restDeploymentVersionStatus" minOccurs="0"/>
<xs:element ref="operations" minOccurs="0"/>
<xs:element name="creatorDisplayName" type="xs:string" minOccurs="0"/>
<xs:element name="creatorGravatarUrl" type="xs:string" minOccurs="0"/>
<xs:element name="planBranchName" type="xs:string" minOccurs="0"/>
<xs:element name="ageZeroPoint" type="xs:dateTime" minOccurs="0"/>

<xs:complexType name="restDeploymentVersionItem" abstract="true">
<xs:element name="id" type="xs:long"/>
<xs:element name="name" type="xs:string" minOccurs="0"/>


For example the startedDate in your screenshot –

startedDate: 1582171641497,

this translates as:

  • Timestamp in milliseconds: 1582171641497
  • GMT: Thursday, February 20, 2020 4:07:21.497 AM
  • Unix Epoch: 1582171641
  • GMT: Thursday, February 20, 2020 4:07:21 AM


Please do not hesitate to reach out if you have any additional questions!


Elias | Bamboo Support

Chandan Datta April 23, 2020

Thanks Elias

Suggest an answer

Log in or Sign up to answer
AUG Leaders

Atlassian Community Events