Logilica Documentation
HomepageDemoBlogContact
  • About Logilica
    • Overview
  • Getting Started
    • Onboarding Data
    • Onboarding Users
    • Setting up Teams
  • Integration
    • Connecting Tools
    • Uploading Custom Data
  • Metrics & Reports
    • Introduction
      • Navigation
      • Dashboards
      • Data Exploration
    • Epics Delivery Tracker
    • Planning
      • Ticket Lead Time
      • Ticket Velocity
      • Ticket Overload
      • Sprint Health
      • Ticket Activities / Risks
    • Code
      • Code Cycle Time
      • Coding Velocity
      • Review Process
      • Developer Health
      • Code Activities / Risks
    • Build
    • Team Management
      • Teams Overview
      • Team Pulse
      • Activity Lens
    • Reports
    • Customization
    • Glossary
  • Configuration
    • User Management
    • Managing Contributors
    • Menu Management
    • Release Detection
    • Targets & Thresholds
    • DORA Configuration
  • Advanced
    • API Token Management
    • Import API
      • API Overview
      • Uploading Planning Data
      • Uploading CI Build Data
        • CDEvents Integration
      • Uploading Test Data
      • Uploading Team Data (beta)
      • Repositories
    • Export API
    • DataStudio
      • Data Models
        • CI Build
        • CI Build Stage
        • Contributor
        • Coverage Commit
        • Coverage File
        • Coverage Label
        • Coverage Test Result
        • Jira Component
        • Jira Epic
        • Jira Hierarchy Issues
        • Jira Issue Hierarchy Link
        • Jira Issue
        • Jira Issue
        • Jira Label
        • Jira Project
        • Jira Release
        • Jira Sprint
        • Project
        • Pull Request
        • Pull Request
        • Release
        • Team
      • Advanced Transformations
    • Integrations: Data Mapping
      • GitHub Projects Support
  • SSO Integration
    • Keycloak SSO
  • Subprocessors
  • Changelog
Powered by GitBook
On this page
  1. Advanced
  2. Import API

Uploading Planning Data

Upload Example Using cURL

In the following, we provide an example of how to push your Planning data to Logilica for storage and built-in analytics. The following depicts all possible fields that can be included in an upload of a ticket or issue, both the mandatory and optional fields.

The cURL POST command is below. Note, that the POST command includes the example API token lgca_UeRxFs_3RYRJEJtdYp7j7Wa6DirG5NjiYslsb and the example workspace myworkspace. The command URL also includes a placeholder for the projectID to associate the uploaded issues with. This projectID is obtained from the pm/projects/create endpoint.

curl --location --request POST \
'https://logilica.io/api/import/v1/pm/<projectID>/issues/create' \
--header 'X-lgca-token: lgca_UeRxFs_3RYRJEJtdYp7j7Wa6DirG5NjiYslsb' \
--header 'x-lgca-domain: myworkspace' \
--header 'Content-Type: application/json' \
--data-raw '[{
    "id": "ABC-123",
    "origin": "JIRA",
    "createdAt": 1689207410,
    "updatedAt": 1689309835,
    "creator": {
        "name": "John Doe",
        "email": "john.doe@myorganisation.com",
        "accountId": "johnDoe",
        "lastActivity": 1701436893
    },
    "reporter": {
        "name": "Jane Doe",
        "email": "jane.doe@myorganisation.com",
        "accountId": "janeDoe",
        "lastActivity": 1699536093
    },
    "assignedAt": 1689207463,
    "assignee": {
        "name": "Sally Smith",
        "email": "sally.smith@myorganisation.com",
        "accountId": "sallySmith",
        "lastActivity": 1701091293
    },
    "inProgressAt": 1689207487,
    "resolvedAt": 1689309835,
    "resolver": {
        "name": "Sally Smith",
        "email": "sally.smith@myorganisation.com",
        "accountId": "sallySmith",
        "lastActivity": 1701436893
    },
    "resolution": "Fix",
    "type": "Task",
    "status": "Completed",
    "statusCategory": "Done",
    "summary": "Revive user API endpoints in each service.",
    "description": "Go into each service and enable the API endpoints that both upload and import user data.",
    "url": "https://myworkspacename.atlassian.net/browse/ABC-123",
    "labels": ["backend"],
    "sprintKeys": ["456"],
    "priority": "Low",
    "storyPointEstimate": 1,
    "parentIssue": "ABC-789",
    "events": [
        {
            "type": "PM_ISSUE_CREATED",
            "author": {
                "name": "John Doe",
                "email": "john.doe@myorganisation.com",
                "accountId": "johnDoe",
                "lastActivity": 1701436893
            },
            "createdAt": 1689207410,
            "to": ""
        },
        {
            "type": "PM_ISSUE_ASSIGNED",
            "author": {
                "name": "John Doe",
                "email": "john.doe@myorganisation.com",
                "accountId": "johnDoe",
                "lastActivity": 1701436893
            },
            "createdAt": 1689207463,
            "to": {
                "name": "Sally Smith",
                "email": "sally.smith@myorganisation.com",
                "accountId": "sallySmith",
                "lastActivity": 1701091293
            }
        },
        {
            "type": "PM_ISSUE_IN_PROGRESS",
            "author": {
               "name": "Sally Smith",
                "email": "sally.smith@myorganisation.com",
                "accountId": "sallySmith",
                "lastActivity": 1701091293
            },
            "createdAt": 1689207487,
            "from": "To Do",
            "to": "In Progress"
        },
        {
            "type": "PM_ISSUE_RESOLVED",
            "author": {
               "name": "Sally Smith",
                "email": "sally.smith@myorganisation.com",
                "accountId": "sallySmith",
                "lastActivity": 1701091293
            },
            "createdAt": 1689309835,
            "from": "In Progress",
            "to": "Done"
        }
    ]
}]'

Method of Importing Planning Data

To ensure the accuracy of data in Logilica, planning data should be imported in the following order:

  1. Create a project and fetch the ID returned to you. You use this ID in subsequent calls to the Logilica Import API for Planning Data.

  2. Import or update sprints

  3. Import or update issues

Data is displayed in Logilica once issues have been imported.

API Schema for Importing Planning Data

Create a new project

Add or Update Sprints

Add or Update Issues

PreviousAPI OverviewNextUploading CI Build Data

Last updated 1 month ago

  • Upload Example Using cURL
  • Method of Importing Planning Data
  • API Schema for Importing Planning Data
  • Create a new project
  • POSTpm/projects/create
  • Add or Update Sprints
  • POSTpm/{projectID}/sprints
  • Add or Update Issues
  • POSTpm/{projectID}/issues/create
post

Add a new project

Body
URLstring ยท uriRequired

The URL by which this project may be reached in a browser

keystringRequired

For Jira style projects, this maps the the issue prefix, eg in "JIRA-123", key would be "JIRA". For gitlab projects, this is the ID of the project.

Pattern: ^[0-9a-zA-z/\-_.]{1,256}$
orgNamestringRequired

The name of organization / group to which the project belongs. orgName combined with key forms a unique identifier for the project.

Pattern: ^[0-9a-zA-z/\-_.]{1,256}$
Responses
200
The ID of the newly created project
application/json
400
Data given doesn't match schema. Return value will be ZodError with validation message
401
Unauthorized
post
POST /api/import/v1/pm/projects/create HTTP/1.1
Host: logilica.io
Content-Type: application/json
Accept: */*
Content-Length: 59

{
  "URL": "https://example.com",
  "key": "text",
  "orgName": "text"
}
{
  "id": "text"
}
post

Add or update a list of sprints

Path parameters
projectIDstringRequired
Body
idstringRequired

unique (per board) ID of sprint

namestringRequired

name of sprint

statestringRequired

current state, e.g. "closed" or "in progress"

goalstringRequired

sprint goal or description

startedAtnumberOptional

UNIX timestamp for when sprint started

endedAtnumberOptional

UNIX timestamp for when sprint is set to ended

completedAtnumberOptional

UNIX timestamp for when the sprint was finished

Responses
200
Empty
400
Data given doesn't match schema. Return value will be ZodError with validation message
401
Unauthorized
404
ProjectID not found
application/json
post
POST /api/import/v1/pm/{projectID}/sprints HTTP/1.1
Host: logilica.io
Content-Type: application/json
Accept: */*
Content-Length: 100

[
  {
    "id": "text",
    "name": "text",
    "state": "text",
    "goal": "text",
    "startedAt": 1,
    "endedAt": 1,
    "completedAt": 1
  }
]

No content

post

Create or update an issue

Path parameters
projectIDstringRequired
Body
idstringRequired

unique global ID of issue

originstringRequired

tool where the issue is from (e.g. Jira)

updatedAtnumberRequired

UNIX timestamp of the last update to the issue

createdAtnumberRequired

UNIX timestamp of when issue was created

assignedAtnumberOptional

UNIX timestamp of when issue was last assigned

inProgressAtnumberOptional

UNIX timestamp of when issue was moved to In Progress

resolvedAtnumberOptional

UNIX timestamp of when issue was moved to Done

resolutionstringOptional

The kind of resolution, e.g. "Fix", "Ignored"

typestringRequired

Issue type (Bug, Task, Subtask, Story, Epic). Subtasks and Epics are treated specially.

statusstringRequired

Issue status

statusCategorystringRequired

Issue status category (one of "To Do", "In Progress", "Done")

summarystringRequired

Issue title

descriptionstringRequired

Issue description

urlstring ยท uriRequired

URL to issue

labelsstring[]Required

Any labels applied to issue

sprintKeysstring[]Required

IDs of sprints the issue belongs to

prioritystringRequired

Priority of issue

storyPointEstimatenumberRequired

Story point estimate

parentIssuestringOptional

When the issue is part of an epic, the ID of that epic

Responses
200
Success - if any sprintIDs were referenced in the dataset, warnings will be given.
application/json
400
Data given doesn't match schema. Return value will be ZodError with validation message
401
Unauthorized
404
ProjectID not found
application/json
post
POST /api/import/v1/pm/{projectID}/issues/create HTTP/1.1
Host: logilica.io
Content-Type: application/json
Accept: */*
Content-Length: 882

[
  {
    "id": "text",
    "origin": "text",
    "updatedAt": 1,
    "createdAt": 1,
    "creator": {
      "name": "text",
      "email": "name@gmail.com",
      "accountId": "text",
      "lastActivity": 1
    },
    "reporter": {
      "name": "text",
      "email": "name@gmail.com",
      "accountId": "text",
      "lastActivity": 1
    },
    "assignedAt": 1,
    "assignee": {
      "name": "text",
      "email": "name@gmail.com",
      "accountId": "text",
      "lastActivity": 1
    },
    "inProgressAt": 1,
    "resolvedAt": 1,
    "resolver": {
      "name": "text",
      "email": "name@gmail.com",
      "accountId": "text",
      "lastActivity": 1
    },
    "resolution": "text",
    "type": "text",
    "status": "text",
    "statusCategory": "text",
    "summary": "text",
    "description": "text",
    "url": "https://example.com",
    "labels": [
      "text"
    ],
    "sprintKeys": [
      "text"
    ],
    "priority": "text",
    "storyPointEstimate": 1,
    "parentIssue": "text",
    "events": [
      {
        "createdAt": 1,
        "sprintID": "text",
        "author": {
          "name": "text",
          "email": "name@gmail.com",
          "accountId": "text",
          "lastActivity": 1
        },
        "type": "PM_ISSUE_CREATED",
        "from": "text",
        "to": "text"
      }
    ]
  }
]
{
  "warnings": {
    "message": "text",
    "ids": [
      "text"
    ]
  }
}