Manifest
Start developing your snap-in with a manifest.yaml
file. The manifest defines the snap-in’s configuration, including its name, description, version, connection details, and functionality.
Begin by setting the values for name
and description
in the template.
Set snap-in functionalities
DevRev supports creating snap-ins for importing data from an external system into DevRev (extraction) and exporting data from DevRev to an external system (loading). Implementing the extraction functionality is essential, while loading is optional.
To define the functionalities, review the functions
section in the manifest.
If loading is not implemented, remove it from the list. This action also removes the option from the DevRev app.
Check the imports
section next.
Update the slug
, display_name
, and description
to match your snap-in.
If loading is not used, remove loader_function
.
Ensure that extractor_function
and loader_function
names correspond with those in the functions
section.
Establish a connection to the external system
Keyrings provide a secure way to store and manage credentials within your DevRev snap-in.
Keyrings are a collection of authentication information, used by a snap-in to authenticate to the external system in API calls. This can include a key (for example, a PAT token or API key), its type and the organization ID for which a key is valid.
This eliminates the need to expose sensitive information like passwords or access tokens directly within your code or configuration files. They also provide a valid token by abstracting OAuth token renewal from the end user, so less work is needed on the developer’s side.
Keyrings are called Connections in the DevRev app.
Configure a keyring
Keyrings are configured in the manifest.yaml
by configuring a keyring_type
, like in the example:
There are some options to consider:
-
kind
Thekind
option can be either “secret” or “oauth2”. The “secret” option is intended for storing various tokens, such as a PAT token. Use of OAuth2 is encouraged when possible. More information is available for secret and oauth2. -
is_subdomain
Theis_subdomain
field relates to the API endpoints being called. When the endpoints for fetching data from an external system include a slug representing the organization—such as for examplehttps://subdomain.freshdesk.com/api/v2/tickets
—set this key to “true”. In this scenario, users creating a new connection are prompted to insert the subdomain.If no subdomain is present in the endpoint URL, set this key to “false”. In this case, provide the
organization_data
part of the configuration. Specify the endpoint in theurl
field to fetch organization data. Users creating a new connection are prompted to select the organization from a list of options, as retrieved from theorganization_data.url
value.