FireDAC Components for Jira Service Desk

Build 21.0.7930

Establishing a Connection

You can create and manage connections with the Data Explorer and the FireDAC Connection Editor wizards. See Connection Definitions for more information on creating connections from code and creating persistent, private, or temporary connections.

Connecting to Jira Service Desk

You can establish a connection to any Jira Service Desk Cloud account or Jira Service Desk Server instance. To connect set the following property:

  • URL (for example: https://yoursitename.atlassian.net).

Authenticating to Jira Service Desk

Basic Authentication

Authenticating with a Cloud Account

To connect to a Cloud account, you'll first need to retrieve an APIToken. To generate one, log in to your Atlassian account and navigate to API tokens > Create API token. The generated token will be displayed.

Supply the following to connect to data:

  • AuthScheme: Set this Basic.
  • User: Set this to the username of the authenticating user.
  • APIToken: Set this to the API token found previously.
Authenticating with a local Server Account

To authenticate with a local server account, you will need to supply the following connection properties:

  • AuthScheme: Set this Basic.
  • User: Set this to the username of the authenticating user.
  • Password: Set this to the password of the authenticating user.
  • URL: Set this to the URL associated with your Jira Service Desk endpoint. For example, https://yoursitename.atlassian.net.

Note: Password has been deprecated for connecting to a Cloud Account and is now used only to connect to a Server Instance.

Authenticate with a Custom OAuth App (3LO)

You can leverage Jira Service Desk's "three-legged" OAuth 2.0 support (3LO) to connect to data without providing your login credentials. See Using OAuth Authentication for an authentication guide.

Authenticating with Crowd

Set the AuthScheme to Crowd. The following connection properties are used to connect to Crowd:

  • User: The CROWD user account.
  • Password: The password associated with the Crowd account.
  • SSOLoginUrl: The login URL associated with the Crowd account. You can find the IDP URL by navigating to your application -> SSO -> SSO information -> Identity provider single sign-on URL.
  • SSOExchangeUrl: The URL used used to exchange the SAML token for JiraServiceDesk cookies. This URL may have the following formats:
    • https://<authority of JiraServiceDesk instance>/plugins/servlet/samlconsumer
    • https://<authority of JiraServiceDesk instance>/plugins/servlet/samlsso
The following SSOProperties are needed to authenticate to Crowd:
  • AppName: The name of the application in which SSO is enabled.
  • AppPassword: The password of the application in which SSO is enabled.

The following is an example connection string:

AuthScheme=Crowd;Url=https://yoursitename.atlassian.net;SSOLoginUrl='https://<authority>/crowd/console/secure/saml/sso.action';User=crowdUserName;Password=crowdPassword;SSOExchangeUrl=https://<authority of JiraServiceDesk instance>/plugins/servlet/samlconsumer;SSO Properties='AppName=CrowdApp;AppPassword=CrowdAppPassword;';

Authenticating with Okta

Set the AuthScheme to Okta. The following connection properties are used to connect to Okta:

  • User: Set this to the Okta user.
  • Password: Set this to Okta password for the user.
  • SSOLoginUrl: Set this to the login url used by the SSO provider.
  • SSOExchangeUrl: The URL used used to exchange the SAML token for JiraServiceDesk cookies. This URL may have the following formats:
    • https://<authority of JiraServiceDesk instance>/plugins/servlet/samlconsumer
    • https://<authority of JiraServiceDesk instance>/plugins/servlet/samlsso
The following SSOProperties are needed to authenticate to Okta:
  • APIToken (optional): Set this to the API Token that the customer created from the Okta org. It should be used when authenticating a user via a trusted application or proxy that overrides OKTA client request context.

The following is an example connection string:

AuthScheme=Okta;Url=https://yoursitename.atlassian.net;SSOLoginUrl='https://example.okta.com/home/appType/0bg4ivz6cJRZgCz5d6/46';User=oktaUserName;Password=oktaPassword;SSOExchangeUrl=https://<authority of JiraServiceDesk instance>/plugins/servlet/samlconsumer;

Accessing Custom Fields

By default, the component surfaces only system fields. To access the custom fields for Issues, set IncludeCustomFields.

Using the FireDAC Connection Editor

Complete the following steps to use the FireDAC Connection Editor to assign a Jira Service Desk connection to a TFDConnection object:

  1. Open a project and drop a TFDPhysCDataJiraServiceDeskDriverLink from the Tool Palette onto the Form Designer.
  2. Drop a TFDConnection object onto the Form Designer.
  3. Double-click the TFDConnection and select CDataJiraServiceDesk in the Driver Id menu.
  4. Define the necessary connection properties.
  5. To execute ad-hoc SQL statements based on this connection, enter SQL commands on the SQL Script tab.
  6. In the Form Designer, select the TFDConnection object and set the Connected property to true.

Using the Data Explorer

Complete the following steps to use the Data Explorer to define persistent connections that can be shared across applications and projects:

  1. Click View > Tool Windows > Data Explorer in RAD Studio and expand the FireDAC node.
  2. Right-click the CData Jira Service Desk Data Source node and click Add New Connection.
  3. Enter a name for the connection. The FireDAC Connection Editor opens.

Working with Persistent Connections

The connections you define in the Data Explorer can be assigned to a TFDConnection object by specifying the connection name in the TFDConnection object's ConnectionDefName property.

Browsing Data and Metadata

The Data Explorer also provides options for browsing Jira Service Desk objects at design time:

  • Expand the CData Jira Service Desk Data Source node in the Data Explorer to view the defined connections.
  • Expand a connection node to find the database objects available for a connection.
  • Drill down to a database object to find metadata such as primary keys.
  • To display data, double-click a table or view or right-click and click View.

Copyright (c) 2021 CData Software, Inc. - All rights reserved.
Build 21.0.7930