Skip to content

Commit

Permalink
Merge branch 'main' into 2128--feature-incident-activity
Browse files Browse the repository at this point in the history
Signed-off-by: Tal <[email protected]>
  • Loading branch information
talboren authored Oct 14, 2024
2 parents 52ce40e + 8a2d747 commit af7ae45
Show file tree
Hide file tree
Showing 22 changed files with 1,151 additions and 100 deletions.
116 changes: 116 additions & 0 deletions .github/workflows/developer_onboarding_notification.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
name: Celebrating Contributions

on:
pull_request_target:
types: [closed]

permissions:
pull-requests: write

jobs:
comment_on_merged_pull_request:
if: github.event.pull_request.merged == true
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4

- name: Set Environment Variables
env:
AUTHOR: ${{ github.event.pull_request.user.login }}
REPO: ${{ github.event.repository.name }}
OWNER: ${{ github.event.repository.owner.login }}
run: |
echo "AUTHOR=${AUTHOR}" >> $GITHUB_ENV
echo "REPO=${REPO}" >> $GITHUB_ENV
echo "OWNER=${OWNER}" >> $GITHUB_ENV
- name: Count Merged Pull Requests
id: count_merged_pull_requests
uses: actions/github-script@v6
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
try {
const author = process.env.AUTHOR;
const repo = process.env.REPO;
const owner = process.env.OWNER;
const { data } = await github.rest.search.issuesAndPullRequests({
q: `repo:${owner}/${repo} type:pr state:closed author:${author}`
});
const prCount = data.items.filter(pr => pr.pull_request.merged_at).length;
core.exportVariable('PR_COUNT', prCount);
} catch (error) {
core.setFailed(`Error counting merged pull requests: ${error.message}`);
}
- name: Comment on the Merged Pull Request
uses: actions/github-script@v6
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
try {
const prCount = parseInt(process.env.PR_COUNT);
const author = process.env.AUTHOR;
const mention = 'talboren';
const prNumber = context.payload.pull_request.number;
const repo = process.env.REPO;
function getRandomEmoji() {
const emojis = ['🎉', '🚀', '💪', '🌟', '🏆', '🎊', '🔥', '👏', '🌈', '🚂'];
return emojis[Math.floor(Math.random() * emojis.length)];
}
function getMessage(count) {
const emoji = getRandomEmoji();
switch(count) {
case 1:
return `${emoji} **Fantastic work @${author}!** Your very first PR to ${repo} has been merged! 🎉🥳\n\n` +
`You've just taken your first step into open-source, and we couldn't be happier to have you onboard. 🙌\n` +
`If you're feeling adventurous, why not dive into another issue and keep contributing? The community would love to see more from you! 🚀\n\n` +
`For any support, feel free to reach out to the developer onboarding lead: @${mention}. Happy coding! 👩‍💻👨‍💻`;
case 2:
return `${emoji} **Well done @${author}!** Two PRs merged already! 🎉🥳\n\n` +
`With your second PR, you're on a roll, and your contributions are already making a difference. 🌟\n` +
`Looking forward to seeing even more contributions from you. The developer onboarding lead: @${mention} is here if you need any help! Keep up the great work! 🚀`;
case 3:
return `${emoji} **You're on fire, @${author}!** Three PRs merged and counting! 🔥🎉\n\n` +
`Your consistent contributions are truly impressive. You're becoming a valued member of our community! 💖\n` +
`Have you considered taking on some more challenging issues? We'd love to see what you can do! 💪\n\n` +
`Remember, @${mention} is always here to support you. Keep blazing that trail! 🚀`;
case 5:
return `${emoji} **High five, @${author}!** You've hit the incredible milestone of 5 merged PRs! 🖐️✨\n\n` +
`Your dedication to ${repo} is outstanding. You're not just contributing code; you're shaping the future of this project! 🌠\n` +
`We'd love to hear your thoughts on the project. Any ideas for new features or improvements? 🤔\n\n` +
`@${mention} and the whole team applaud your efforts. You're a superstar! 🌟`;
case 10:
return `${emoji} **Double digits, @${author}!** 10 merged PRs is a massive achievement! 🏆🎊\n\n` +
`Your impact on ${repo} is undeniable. You've become a pillar of our community! 🏛️\n` +
`We'd be thrilled to have you take on a mentorship role for newer contributors. Interested? 🧑‍🏫\n\n` +
`@${mention} and everyone here are in awe of your contributions. You're an open source hero! 🦸‍♀️🦸‍♂️`;
default:
if (count > 10) {
return `${emoji} **Incredible, @${author}!** You've merged your ${count}th PR! 🎯🎊\n\n` +
`Your ongoing commitment to ${repo} is truly remarkable. You're a driving force in our community! 🚀\n` +
`Your contributions are helping to shape the future of this project. What exciting features or improvements do you envision next? 🔮\n\n` +
`@${mention} and the entire team are grateful for your dedication. You're an inspiration to us all! 💫`;
} else {
return `${emoji} **Great job, @${author}!** You've merged your ${count}th PR! 🎊\n\n` +
`Your contributions to ${repo} are making a real difference. Keep up the fantastic work! 💪\n` +
`Remember, every PR counts and helps improve the project. What will you tackle next? 🤔\n\n` +
`@${mention} is here if you need any guidance. Onward and upward! 🚀`;
}
}
}
const message = getMessage(prCount);
await github.rest.issues.createComment({
owner: process.env.OWNER,
repo: process.env.REPO,
issue_number: prNumber,
body: message
});
} catch (error) {
core.setFailed(`Error creating comment: ${error.message}`);
}
169 changes: 91 additions & 78 deletions docs/mint.json
Original file line number Diff line number Diff line change
Expand Up @@ -107,84 +107,97 @@
{
"group": "Supported Providers",
"pages": [
"providers/documentation/aks-provider",
"providers/documentation/appdynamics-provider",
"providers/documentation/axiom-provider",
"providers/documentation/azuremonitoring-provider",
"providers/documentation/centreon-provider",
"providers/documentation/clickhouse-provider",
"providers/documentation/cloudwatch-provider",
"providers/documentation/console-provider",
"providers/documentation/coralogix-provider",
"providers/documentation/datadog-provider",
"providers/documentation/discord-provider",
"providers/documentation/elastic-provider",
"providers/documentation/gcpmonitoring-provider",
"providers/documentation/github_workflows_provider",
"providers/documentation/gitlab-provider",
"providers/documentation/gitlabpipelines-provider",
"providers/documentation/google_chat-provider",
"providers/documentation/grafana-provider",
"providers/documentation/grafana_incident-provider",
"providers/documentation/grafana_oncall-provider",
"providers/documentation/http-provider",
"providers/documentation/ilert-provider",
"providers/documentation/incidentio-provider",
"providers/documentation/incidentmanager-provider",
"providers/documentation/jira-provider",
"providers/documentation/jira-on-prem-provider",
"providers/documentation/kibana-provider",
"providers/documentation/kubernetes-provider",
"providers/documentation/linear_provider",
"providers/documentation/linearb-provider",
"providers/documentation/mailchimp-provider",
"providers/documentation/mattermost-provider",
"providers/documentation/microsoft-planner-provider",
"providers/documentation/mock-provider",
"providers/documentation/mongodb-provider",
"providers/documentation/mysql-provider",
"providers/documentation/mailgun-provider",
"providers/documentation/netdata-provider",
"providers/documentation/new-relic-provider",
"providers/documentation/ntfy-provider",
"providers/documentation/openobserve-provider",
"providers/documentation/openshift-provider",
"providers/documentation/opsgenie-provider",
"providers/documentation/pagerduty-provider",
"providers/documentation/pagertree-provider",
"providers/documentation/pingdom-provider",
"providers/documentation/planner-provider",
"providers/documentation/postgresql-provider",
"providers/documentation/pushover-provider",
"providers/documentation/quickchart-provider",
"providers/documentation/redmine-provider",
"providers/documentation/resend-provider",
"providers/documentation/rollbar-provider",
"providers/documentation/sendgrid-provider",
"providers/documentation/sentry-provider",
"providers/documentation/signalfx-provider",
"providers/documentation/signl4-provider",
"providers/documentation/site24x7-provider",
"providers/documentation/slack-provider",
"providers/documentation/snowflake-provider",
"providers/documentation/smtp-provider",
"providers/documentation/splunk-provider",
"providers/documentation/squadcast-provider",
"providers/documentation/ssh-provider",
"providers/documentation/statuscake-provider",
"providers/documentation/sumologic-provider",
"providers/documentation/teams-provider",
"providers/documentation/telegram-provider",
"providers/documentation/template",
"providers/documentation/trello-provider",
"providers/documentation/twilio-provider",
"providers/documentation/uptimekuma-provider",
"providers/documentation/victoriametrics-provider",
"providers/documentation/webhook-provider",
"providers/documentation/websocket-provider",
"providers/documentation/zabbix-provider",
"providers/documentation/zenduty-provider"
]
"providers/documentation/aks-provider",
"providers/documentation/appdynamics-provider",
"providers/documentation/auth0-provider",
"providers/documentation/axiom-provider",
"providers/documentation/azuremonitoring-provider",
"providers/documentation/bash-provider",
"providers/documentation/bigquery-provider",
"providers/documentation/centreon-provider",
"providers/documentation/clickhouse-provider",
"providers/documentation/cloudwatch-provider",
"providers/documentation/console-provider",
"providers/documentation/coralogix-provider",
"providers/documentation/datadog-provider",
"providers/documentation/discord-provider",
"providers/documentation/dynatrace-provider",
"providers/documentation/elastic-provider",
"providers/documentation/gcpmonitoring-provider",
"providers/documentation/github-provider",
"providers/documentation/github_workflows_provider",
"providers/documentation/gitlab-provider",
"providers/documentation/gitlabpipelines-provider",
"providers/documentation/gke-provider",
"providers/documentation/google_chat-provider",
"providers/documentation/grafana-provider",
"providers/documentation/grafana_incident-provider",
"providers/documentation/grafana_oncall-provider",
"providers/documentation/http-provider",
"providers/documentation/ilert-provider",
"providers/documentation/incidentio-provider",
"providers/documentation/incidentmanager-provider",
"providers/documentation/jira-on-prem-provider",
"providers/documentation/jira-provider",
"providers/documentation/kafka-provider",
"providers/documentation/keep-provider",
"providers/documentation/kibana-provider",
"providers/documentation/kubernetes-provider",
"providers/documentation/linear_provider",
"providers/documentation/linearb-provider",
"providers/documentation/mailchimp-provider",
"providers/documentation/mailgun-provider",
"providers/documentation/mattermost-provider",
"providers/documentation/microsoft-planner-provider",
"providers/documentation/mock-provider",
"providers/documentation/mongodb-provider",
"providers/documentation/mysql-provider",
"providers/documentation/netdata-provider",
"providers/documentation/new-relic-provider",
"providers/documentation/ntfy-provider",
"providers/documentation/openobserve-provider",
"providers/documentation/openshift-provider",
"providers/documentation/opsgenie-provider",
"providers/documentation/pagerduty-provider",
"providers/documentation/pagertree-provider",
"providers/documentation/parseable-provider",
"providers/documentation/pingdom-provider",
"providers/documentation/planner-provider",
"providers/documentation/postgresql-provider",
"providers/documentation/prometheus-provider",
"providers/documentation/pushover-provider",
"providers/documentation/python-provider",
"providers/documentation/quickchart-provider",
"providers/documentation/redmine-provider",
"providers/documentation/resend-provider",
"providers/documentation/rollbar-provider",
"providers/documentation/sendgrid-provider",
"providers/documentation/sentry-provider",
"providers/documentation/service-now-provider",
"providers/documentation/signalfx-provider",
"providers/documentation/signl4-provider",
"providers/documentation/site24x7-provider",
"providers/documentation/slack-provider",
"providers/documentation/smtp-provider",
"providers/documentation/snowflake-provider",
"providers/documentation/splunk-provider",
"providers/documentation/squadcast-provider",
"providers/documentation/ssh-provider",
"providers/documentation/statuscake-provider",
"providers/documentation/sumologic-provider",
"providers/documentation/teams-provider",
"providers/documentation/telegram-provider",
"providers/documentation/template",
"providers/documentation/trello-provider",
"providers/documentation/twilio-provider",
"providers/documentation/uptimekuma-provider",
"providers/documentation/victoriametrics-provider",
"providers/documentation/webhook-provider",
"providers/documentation/websocket-provider",
"providers/documentation/zabbix-provider",
"providers/documentation/zenduty-provider"
]

}
]
},
Expand Down
11 changes: 6 additions & 5 deletions docs/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

56 changes: 56 additions & 0 deletions docs/providers/documentation/auth0-provider.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
---
title: "Auth0"
sidebarTitle: "Auth0 Provider"
description: "Auth0 provider allows interaction with Auth0 APIs for authentication and user management."
---

## Inputs

- `client_id`: str : The client ID for the Auth0 application.
- `client_secret`: str : The client secret for the Auth0 application.
- `audience`: str : The audience for the API authorization request.
- `grant_type`: str : The type of authorization grant requested (e.g., `client_credentials`).

## Outputs

- `access_token`: The access token issued by Auth0 for authenticated requests.
- `expires_in`: The time in seconds before the access token expires.
- `token_type`: The type of token, typically `Bearer`.

## Authentication Parameters

To authenticate with Auth0, the following parameters are needed:
- **client_id**: The unique identifier for your Auth0 application.
- **client_secret**: A secret associated with your application, used for secure communication.
- **audience**: Defines the API resources you're trying to access.

These parameters can be retrieved from your Auth0 dashboard under the application's settings.

## Connecting with the Provider

The Auth0 provider connects to both the **Authentication API** and the **Management API**, enabling functionality such as token-based authentication and user management. Depending on your needs, you can:
- Use the **Authentication API** to obtain access tokens, manage user profiles, or handle multi-factor authentication.
- Use the **Management API** to automate the configuration of your Auth0 environment, register applications, manage users, and more.

## Example of usage

```yaml
workflow:
id: auth0-example
description: Auth0 example
triggers:
- type: manual
actions:
- name: auth0
provider:
type: auth0
config: "{{ providers.auth0config }}"
with:
client_id: "{{ secrets.auth0_client_id }}"
client_secret: "{{ secrets.auth0_client_secret }}"
audience: "https://api.example.com"
grant_type: "client_credentials"

##Usefull Links
-[Auth0 API Documentation](https://auth0.com/docs/api)
-[Auth0 as an authentication method for keep](https://docs.keephq.dev/deployment/authentication/auth0-auth)
Loading

0 comments on commit af7ae45

Please sign in to comment.