I have been trying to set up an app that uses some forge modules and some connect modules. For this, I started from the Atlassian Connect Express hello world template and then tried to create the new manifest.yml file but I am running into some issues that I can’t figure out and I would greatly appreciate some help.
starting from the default atlassian-connect.json generated by the ACE template we have
{
"key": "my-app",
"name": "My app",
"description": "My very first app",
"baseUrl": "{{localBaseUrl}}",
"authentication": {
"type": "jwt"
},
"lifecycle": {
"installed": "/installed"
},
"scopes": [
"READ"
],
"apiMigrations":{
"signed-install": true
},
"modules": {
"generalPages": [
{
"key": "hello-world-page-jira",
"location": "system.top.navigation.bar",
"name": {
"value": "Hello World"
},
"url": "/hello-world",
"conditions": [{
"condition": "user_is_logged_in"
}]
},
{
"key": "hello-world-page-confluence",
"location": "system.header/left",
"name": {
"value": "Hello World"
},
"url": "/hello-world",
"conditions": [{
"condition": "user_is_logged_in"
}]
}
]
}
}
when I hit npm start
my app is registered and I can open the general page as expected. So the base template works fine.
But following the steps from this chapter I arrived at this manifest file
connectModules:
jira:generalPages:
- key: hello-world-page-jira
location: system.top.navigation.bar
name: Hello World!
url: /hello-world
displayConditions:
isLoggedIn: true
jira:lifecycle:
- installed: /installed
remotes:
- key: connect
baseUrl: https://cc9c-79-142-135-236.ngrok.io/
app:
id: ari:cloud:ecosystem::app/0bd60f8e-750e-4c76-b75f-d1934b89c3a7
connect:
key: connect-hello-world
remote: connect
permissions:
scopes:
- read:connect-jira
unfortunately I did not find information how to use forge with ACE so I am not sure if I should leave the registration of the app to ACE or use forge but so far, neither of these approaches worked for me.
I tried leaving the atlassian-connect.json untouched and registering it with ACE but then the app would simply use the atlassian-connect app, not the forge app (I chose different names for the general pages). So I tried removing the atlassian-connect.json
and replacing the root response in /routes/index/js
from /atlassian-connect.json
to /manifest.yml
and use forge deploy.
but when I run forge deploy
I am getting an error
Found manifest file
Manifest is a valid YAML
Manifest validation failed
Validation errors: {
"validationResult": {
"tid": "8fb4cc6cef9cbc7f",
"code": 400,
"type": "APIError",
"message": "RequestValidationError RequestValidationError: Schema validation error "
}
}
Error: Deployment failed
Error: Deployment failed
at ArtifactDeployer.handleErrorEvent (C:\Users\Ilewicz\AppData\Roaming\npm\node_modu
at ArtifactDeployer.pollAndCheckEvents (C:\Users\Ilewicz\AppData\Roaming\npm\node_mo
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async ArtifactDeployer.monitorDeployment (C:\Users\Ilewicz\AppData\Roaming\npm\no
at async ArtifactDeployer.deploy (C:\Users\Ilewicz\AppData\Roaming\npm\node_modules\
at async PackageUploadDeployCommand.execute (C:\Users\Ilewicz\AppData\Roaming\npm\no
m\node_modules\@forge\cli\out\command-line\command.js:76:32)
Am I doing something wrong? I tried everything I could come up with, some further ideas would be greatly appreciated