Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/leodog896/co-authored-by-deno
deno deploy function for co-authored-by
https://github.com/leodog896/co-authored-by-deno
co-authored-by deno deno-deploy email github server
Last synced: 3 days ago
JSON representation
deno deploy function for co-authored-by
- Host: GitHub
- URL: https://github.com/leodog896/co-authored-by-deno
- Owner: LeoDog896
- License: mit
- Created: 2023-03-30T14:05:23.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-10-30T16:47:29.000Z (about 1 year ago)
- Last Synced: 2023-10-30T17:42:52.128Z (about 1 year ago)
- Topics: co-authored-by, deno, deno-deploy, email, github, server
- Language: TypeScript
- Homepage: https://co-authored-by.deno.dev
- Size: 29.3 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# co-authored-by-deno
deno deploy function for [co-authored-by](https://github.com/LeoDog896/co-authored-by).
The API is deployed on [`https://co-authored-by.deno.dev`](https://co-authored-by.deno.dev). Usage:
```bash
curl https://co-authored-by.deno.dev/username
```For example:
```bash
curl https://co-authored-by.deno.dev/LeoDog896 # returns "Co-authored-by: Tristan F. "
```## How does the API grab emails?
It does it in 4 steps, with a fallback to the next step if the previous one fails.
1. Find a primary email address (are any social media accounts attached? Are
one of these mail?)
2. Find an email address from the latest commit (if this is a non-shadow email,
use it).
3. Use the modern shadow email (with an id, in the format
`[email protected]`).
4. Generate a legacy shadow email (without an ID).## API Signature
`/` - `400`, Bad Request, no username was provided (message can vary)
`/` - `200`, returns the exact [Co-authored-by](https://docs.github.com/en/pull-requests/committing-changes-to-your-project/creating-and-editing-commits/creating-a-commit-with-multiple-authors) footer format as one line.
> **Note**
> If the username does not exist OR the username is an organization, a `404` code will be returned instead.