https://github.com/wavy-cat/petpet-go
Petpet GIF generator, written in Go
https://github.com/wavy-cat/petpet-go
discord go petpet web
Last synced: 4 months ago
JSON representation
Petpet GIF generator, written in Go
- Host: GitHub
- URL: https://github.com/wavy-cat/petpet-go
- Owner: wavy-cat
- License: bsl-1.0
- Created: 2024-09-16T13:11:50.000Z (almost 2 years ago)
- Default Branch: master
- Last Pushed: 2026-02-01T04:46:11.000Z (5 months ago)
- Last Synced: 2026-02-01T15:49:51.562Z (5 months ago)
- Topics: discord, go, petpet, web
- Language: Go
- Homepage:
- Size: 1010 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# petpet-go



A web service for generating petpet GIFs based on a Discord user's avatar.
---
## Usage
GET `/ds/{user_id}.gif`
POST `/custom`
### Path parameters
| Name | Type | Description |
|-------------|-----------|-----------------------|
| `{user_id}` | Snowflake | The Discord user's ID |
### Query parameters
| Name | Default | Type | Description |
|------------|---------|------------------|----------------------------------------------------|
| `delay` | `4` | Unsigned Integer | GIF speed. Bigger is slower |
| `no-cache` | `false` | Boolean | Whether to disable caching (Cache-Control headers) |
### Upload (POST /custom)
Send a `multipart/form-data` request with a file field named `image` containing a PNG or JPEG.
The upload is limited to 5MB and a maximum of 1 MP.
## Getting started
* Using Docker:
`docker run ghcr.io/wavy-cat/petpet-go`
* Using binaries:
Download the [latest release](https://github.com/wavy-cat/petpet-go/releases/latest) and run it.
* Compiling (you need [Go compiler](https://go.dev/dl/)):
`go run github.com/wavy-cat/petpet-go/cmd/app`
## Configuration
Currently, config parameters can be specified either in the `config.yml` file or via environment variables.
Look at the [sample config](config.sample.yml) with comments (including environment variable names)
## PetPet in other languages
* **Python**: [nakidai/petthecord](https://github.com/nakidai/petthecord)
* **Rust**: [messengernew/petpet-api](https://github.com/messengernew/petpet-api)
* **C**: [nakidai/cptc](https://github.com/nakidai/cptc)