"Schema validation error" during deploy

I am working on creating a custom hook for pull requests and am encountering an error “message”: "RequestValidationError RequestValidationError: Schema validation error " during the deploy action.

I am a complete newbie and any help is appreciated!

My manifest.yml is as follows:

Hi @JasonLSelburg and welcome to our community,

There are a few issues with the manifest.yml file in the screenshot and I think that, instead of trying to update it, it might be more effective for me to give you a few pointers on how to get started.

Here is an example of a manifest.yml file for an app which will respond to the “Pull request created” event. You can read more about this app here.
If you would like to try this one out, the instructions are available on the README.md file of the app repository.

If you prefer to start from scratch, I would use these options in the Forge CLI:

? Select a category: Triggers and Validators
? Select a product: Show All
? Select a template: product-trigger

This will result in the following manifest.yml:

modules:
  trigger:
    - key: my-trigger
      function: main
      events:
        - avi:jira:created:issue
  function:
    - key: main
      handler: index.run
app:
  runtime:
    name: nodejs20.x
  id: ari:cloud:ecosystem::app/<appId>

To use this in Bitbucket to respond to the PR created and updated event, all you need to do is to update the events part with the desired Pull request events.

Following your example, the manifest.yml should be updated in the following way:

modules:
  trigger:
    - key: my-trigger
      function: main
      events:
        - avi:bitbucket:created:pullrequest
       - avi:bitbucket:updated:pullrequest
  function:
    - key: main
      handler: index.run
app:
  runtime:
    name: nodejs20.x
  id: ari:cloud:ecosystem::app/<appId>

Let me know how this goes,
Caterina

1 Like

Thank you! I will try this out this week. Much appreciated!

1 Like