Skip to content

Commit

Permalink
Add API bitbucket integration.
Browse files Browse the repository at this point in the history
  • Loading branch information
ethan42 committed Nov 25, 2024
1 parent ca977b3 commit 6589886
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions pipelines/bitbucket/api/mayhem.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Scan an API -> get a SARIF report

pipelines:
custom:
api-testing:
- step:
name: 'API Security Testing'
script:
# Install the Mayhem CLI
- curl -O https://app.mayhem.security/cli/mapi/linux-musl/latest/mapi && chmod +x ./mapi
# Login
- ./mapi --mayhem-url https://app.mayhem.security login $MAYHEM_TOKEN
# Run Mayhem and generate SARIF and JUnit reports
- ./mapi run forallsecure/bitbucket-example/api 60s $API_SPEC --url $API_URL --sarif api_mayhem.sarif --junit api_mayhem.junit
# Store results as artifacts
artifacts:
- api_mayhem.sarif
- api_mayhem.junit
test:
reports:
junit: api_mayhem.junit

0 comments on commit 6589886

Please sign in to comment.