Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions .github/workflows/typo-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Typo Check

on:
pull_request:
branches:
- master
- main
push:
branches:
- master
- main

jobs:
typo-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.x"

- name: Install codespell
run: pip install codespell

- name: Run codespell
run: |
codespell \
--skip=".git,*.svg,*.css,*.js" \
--ignore-words-list="crate,ect,requestor,stanger,intrest" \
docs/ src/ *.md *.yml
10 changes: 10 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
repos:
- repo: https://github.com/codespell-project/codespell
rev: v2.2.6
hooks:
- id: codespell
name: Check for typos
args:
- --skip=.git,*.svg,*.css,*.js
- --ignore-words-list=crate,ect,requestor,stanger,intrest
types_or: [markdown, yaml, python, html]
10 changes: 5 additions & 5 deletions docs/api/account/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ If the request succeeds, `meta.errors` will be null, and if the request fails, `
***

> [!note]
> Calls related to account security, such as managing your password or updating MFA settings are located in the [Oauth / MFA Managment](oauth.md) section.
> Calls related to account security, such as managing your password or updating MFA settings are located in the [Oauth / MFA Management](oauth.md) section.

## About
<!-- official-doc: https://dev.groupme.com/docs/v3#users_me -->
Expand Down Expand Up @@ -112,7 +112,7 @@ POST /users/update

* *avatar_url*

string — A valid image URL proccesed by GroupMe's [image service](https://dev.groupme.com/docs/image_service)
string — A valid image URL processed by GroupMe's [image service](https://dev.groupme.com/docs/image_service)

* *name*

Expand Down Expand Up @@ -272,7 +272,7 @@ Status: 200 OK

## Update Major Tags

This call is only allowed for accounts that are members of a school domain, which is not an easy proccess to automate and thus will not be fully documented. HOWEVER, once you are in a domain, you have a few additional calls availible for your account.
This call is only allowed for accounts that are members of a school domain, which is not an easy process to automate and thus will not be fully documented. HOWEVER, once you are in a domain, you have a few additional calls available for your account.

```json linenums="1" title="HTTP Request"
PUT /directories/user/majors
Expand Down Expand Up @@ -302,7 +302,7 @@ Status: 201 Accepted

## Set Graduation Year and Domain Visibility

This call is only allowed for accounts that are members of a school domain, which is not an easy proccess to automate and thus will not be fully documented. HOWEVER, once you are in a domain, you have a few additional calls availible for your account.
This call is only allowed for accounts that are members of a school domain, which is not an easy process to automate and thus will not be fully documented. HOWEVER, once you are in a domain, you have a few additional calls available for your account.

This call specifies your graduation year tag inside of your profile as well as what level of visibility you want your profile to be at within the campus domain.

Expand Down Expand Up @@ -372,7 +372,7 @@ Status: 200 OK

## Enable SMS mode

Enables SMS mode for N hours, where N is at most 48. After N hours have elapsed, user will receive push notfications.
Enables SMS mode for N hours, where N is at most 48. After N hours have elapsed, user will receive push notifications.

```json linenums="1" title="HTTP Request"
POST /users/sms_mode
Expand Down
10 changes: 5 additions & 5 deletions docs/api/account/oauth.md
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ Your client follows one of a few methods to verify that MFA ID, and then passes

Because sending a text is asynchronous, you need to wait and validate that the server has received your SMS before attempting to use the MFA ID. You can do this via polling the ID to see if it's validated yet.

You can use this call to check if any MFA ID is valid, not just ones where you're sending the text. It's most relevant here, so thats why we include it.
You can use this call to check if any MFA ID is valid, not just ones where you're sending the text. It's most relevant here, so that's why we include it.

```json linenums="1" title="HTTP Request"
GET /verifications/:mfa_id
Expand Down Expand Up @@ -286,10 +286,10 @@ This call activates an MFA channel for your account, it works just like logging

You make this call once without an MFA verification object, receive an MFA ID for the interaction, validate it using the steps detailed in the [Handling MFA Challenges](#handling-mfa-challenges) section, then make this call a second time including the now verified MFA ID.

After establishing the MFA channel you must enable it with a seperate call.
After establishing the MFA channel you must enable it with a separate call.

> [!important]
> Activating MFA will log you out *everywhere*, including 3rd party Oauth apps. This proccess will invalidate your current API token and return a new one that you should use to make subsequent API calls.
> Activating MFA will log you out *everywhere*, including 3rd party Oauth apps. This process will invalidate your current API token and return a new one that you should use to make subsequent API calls.

```json linenums="1" title="HTTP Request"
POST /user/mfa
Expand All @@ -311,9 +311,9 @@ POST /user/mfa

* *code*

string - A verified MFA ID obtained by completing the verification challenge. This only needs to be inlcuded on the second request you make to this endpoint.
string - A verified MFA ID obtained by completing the verification challenge. This only needs to be included on the second request you make to this endpoint.

On the first call you make, whithout sending a verification code, the response should look like this:
On the first call you make, without sending a verification code, the response should look like this:

```json linenums="1" title="HTTP Response"
Status: 202 Accepted
Expand Down
2 changes: 1 addition & 1 deletion docs/api/bots/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ POST /bots

* *avatar_url*

string - a URL to an image which will be the bot's avatar. This image MUST be proccessed by GroupMe's [Image Service](../uploads/images.md) before it can be sent.
string - a URL to an image which will be the bot's avatar. This image MUST be processed by GroupMe's [Image Service](../uploads/images.md) before it can be sent.

* *callback_url*

Expand Down
4 changes: 2 additions & 2 deletions docs/api/common/attachments.md
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ Read more about calendar events [here](../conversations/calendar.md)

* *type*

string - must be "event" for a callendar event attachment
string - must be "event" for a calendar event attachment

* *event_id*

Expand Down Expand Up @@ -309,7 +309,7 @@ This attachment type is read-only and used exclusively by Copilot in its message

## Partial Image

This attachment type is read-only and used exclusively by Copilot in its messages to attach partial images as they are being generated. Copilot will edit its messages containing in-progress images as they finish. When an image is complete, its partial image attachement is swapped for a regular image attachment containing a CDN URL.
This attachment type is read-only and used exclusively by Copilot in its messages to attach partial images as they are being generated. Copilot will edit its messages containing in-progress images as they finish. When an image is complete, its partial image attachment is swapped for a regular image attachment containing a CDN URL.

```json linenums="1" title="Object Structure"
{
Expand Down
4 changes: 2 additions & 2 deletions docs/api/conversations/calendar.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: "Calandar Events"
description: "Learn how to interact with GroupMe's Calandar Events via the API."
title: "Calendar Events"
description: "Learn how to interact with GroupMe's Calendar Events via the API."
---

# Calendar Events
Expand Down
2 changes: 1 addition & 1 deletion docs/api/conversations/pins.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ If the request succeeds, `meta.errors` will be null, and if the request fails, `

Pins a message.

Note that trying to pin a message which is already pinned will result in an unhelpful 400 error. It may be difficult to programatically determine whether a given call fails due to an actual bad request, or if it's just because the message has already been pinned. For now, you just have to enumerate the pinned mesages and see if there's a match, or get the messatge object and see if the "pinned_at" field is null
Note that trying to pin a message which is already pinned will result in an unhelpful 400 error. It may be difficult to programmatically determine whether a given call fails due to an actual bad request, or if it's just because the message has already been pinned. For now, you just have to enumerate the pinned messages and see if there's a match, or get the messatge object and see if the "pinned_at" field is null

```json linenums="1" title="HTTP Request"
POST /conversations/:conversation_id/messages/:message_id/pin
Expand Down
4 changes: 2 additions & 2 deletions docs/api/dms/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ GET /chats/:chat_id

* *chat_id*

string - this is the compound ID of the chat, consisting of two seperate user IDs. It should look something like `93645911+118825642`.
string - this is the compound ID of the chat, consisting of two separate user IDs. It should look something like `93645911+118825642`.

```json linenums="1" title="HTTP Response"
Status: 200 OK
Expand Down Expand Up @@ -151,7 +151,7 @@ DELETE /chats/:chat_id

* *chat_id*

string - this is the compound ID of the chat, consisting of two seperate user IDs. It should look something like `93645911+118825642`.
string - this is the compound ID of the chat, consisting of two separate user IDs. It should look something like `93645911+118825642`.

```json linenums="1" title="HTTP Response"
Status: 200 OK
Expand Down
2 changes: 1 addition & 1 deletion docs/api/groups/campus.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ Status: 200 OK

## Index Members

Return a list containing all of the users who are visible to you within the campus directory. Note that the responses you get are also dependant on the privacy status of other users in the directory. Some people have their profiles set to be visible to only their major or graduation year, or hidden entirely.
Return a list containing all of the users who are visible to you within the campus directory. Note that the responses you get are also dependent on the privacy status of other users in the directory. Some people have their profiles set to be visible to only their major or graduation year, or hidden entirely.

> [!important]
> This request is relative to `https://api.groupme.com/v1/`, not `https://api.groupme.com/v3/`.
Expand Down
6 changes: 3 additions & 3 deletions docs/api/groups/directories.md
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ Status: 201 Created

## Search Public Groups

Returns a list of public groups based on search terms or lattitude/longitude coordinates. If a location is supplied, groups will be orderd roughly by distance from that point.
Returns a list of public groups based on search terms or latitude/longitude coordinates. If a location is supplied, groups will be ordered roughly by distance from that point.

Returned groups will be split into 4 different lists, depending on where they were found.
* `directories` if you're a member of a university campus directory and matching results were found in your school domain
Expand Down Expand Up @@ -171,9 +171,9 @@ GET https://api.groupme.com/v1/search

String - A set of search terms to filter groups in the response.

* *lattitude*
* *latitude*

Decimal - The lattitude coordinate for a point used to sort groups by their distance.
Decimal - The latitude coordinate for a point used to sort groups by their distance.

* *longitude*

Expand Down
2 changes: 1 addition & 1 deletion docs/api/groups/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ POST /groups/:id/update

* *show_join_question*

boolean - If true, members must answer a question prompt in oder to request to join a group. The question defaults to "Why do you want to join this group". `"requires_approval"` must be true for this value to take effect.
boolean - If true, members must answer a question prompt in order to request to join a group. The question defaults to "Why do you want to join this group". `"requires_approval"` must be true for this value to take effect.
* *join_question*

object - Has two properties, `"type"` must always be set to `"join_reason/questions/text"` , and `"text"` is the custom join question. Both `"requires_approval"` and `"show_join_question"` must be true for this value to take effect.
Expand Down
2 changes: 1 addition & 1 deletion docs/api/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ If you have any questions or would like to get in touch, please join the [GroupM
[Direct Messages]: dms/index.md
[Conversation Management]: conversations/index.md
[Common API Structures]: common/index.md
[CDN Management]: uploads/indexs.md
[CDN Management]: uploads/index.md


***
2 changes: 1 addition & 1 deletion docs/api/uploads/images.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ You must to provide the **X-Access-Token** user API token as a header.
**Response**

Your response will be of the same format as above:
```json linenums="1" titile="HTTP Response"
```json linenums="1" title="HTTP Response"
Status: 200 OK
{
"payload": {
Expand Down
10 changes: 5 additions & 5 deletions docs/api/ws/messageTypes.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ The following sections describe the different message types you may receive, alo

## `ping`

A keep-alive heartbeat message. This message is sent down every 30 seconds in order to ensure your client is still listening. You can generally ignore these messages if you dont plan on sending them, as the server will keep the connection alive on its own. Sending a `ping` type message causes the server to echo one back and then supresses the server from sending pings for the next 30 seconds. By timing how long it takes to send this message and then receive an echoed ping from the server you can effectively calculate roundtrip ping latancy for the WebSocket gateway.
A keep-alive heartbeat message. This message is sent down every 30 seconds in order to ensure your client is still listening. You can generally ignore these messages if you dont plan on sending them, as the server will keep the connection alive on its own. Sending a `ping` type message causes the server to echo one back and then suppresses the server from sending pings for the next 30 seconds. By timing how long it takes to send this message and then receive an echoed ping from the server you can effectively calculate roundtrip ping latancy for the WebSocket gateway.

This and [`typing`](#typing) are the only two message types clients are permitted by the API to send.

Expand Down Expand Up @@ -94,7 +94,7 @@ Generally, incoming messages will look like this:

* *subject*

object - The message object this push is refering to.
object - The message object this push is referring to.

* *received_at*

Expand Down Expand Up @@ -155,7 +155,7 @@ However, in some cases you may observe a system message with an attached `subjec

* *subject*

object - The message object this push is refering to.
object - The message object this push is referring to.

* *received_at*

Expand Down Expand Up @@ -208,7 +208,7 @@ Generally, incoming messages will look like this:

* *subject*

object - The message object this push is refering to.
object - The message object this push is referring to.

* *received_at*

Expand Down Expand Up @@ -264,7 +264,7 @@ However, in some cases you may observe a system message with an attached `subjec

* *subject*

object - The message object this push is refering to.
object - The message object this push is referring to.

* *received_at*

Expand Down
43 changes: 43 additions & 0 deletions docs/contributing/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,49 @@ Make sure to follow the existing style and structure of the documentation. This

We use a special flavor of Markdown that supports additional features like admonitions and special UI elements. You can dind its reference in the [Material for MKDocs Reference Guide](https://squidfunk.github.io/mkdocs-material/reference/)

```


#### Linting and Typo Checking

This project uses [codespell](https://github.com/codespell-project/codespell) to catch common typos before they make it into the documentation. We recommend setting up [pre-commit](https://pre-commit.com/) to automatically check for typos before each commit.

**Installing pre-commit:**

```bash
pip install pre-commit
pre-commit install
```

After running these commands, codespell will automatically check your changes for typos every time you commit. If typos are found, the commit will be blocked until you fix them.

**Fixing typos:**

If codespell finds a typo, it will show you the file, line number, and suggest corrections:

```
docs/api/groups/index.md:123: receive ==> receive
```

Simply open the file, navigate to the line, and fix the typo. Then stage your changes and commit again.

**Running the check manually:**

You can also run the typo check manually at any time:

```bash
pre-commit run --all-files
```

Or run codespell directly:

```bash
pip install codespell
codespell docs/
```

If codespell flags a word that is intentionally spelled that way (like a technical term or API field name), you can add it to the ignore list in `.pre-commit-config.yaml`.

***

### Step 5: Commit Your Changes
Expand Down
4 changes: 2 additions & 2 deletions docs/examples/dinobot.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ DinoBot is a simple webhook bot for GroupMe, originally written in C# by Microso

Before you can run DinoBot, you need to set up a GroupMe bot and a callback URL that points to your server/host where the bot will receive and handle messages. The easisest way to create a bot is to use [GroupMe's Bot Creation form](https://dev.groupme.com/bots/new), where you can specify the bot's name, avatar, and callback URL. Alternatively, you can create a bot using the API and your user account's API token. Read more about creating and managing bots in the [Bots API Reference](../api/bots/index.md).

After registering a new bot with GroupMe, create a new Node.js project and install express.js (An HTTP server framework for JavaScript we will use to catch GroupMe's POST messags to our callback URL).
After registering a new bot with GroupMe, create a new Node.js project and install express.js (An HTTP server framework for JavaScript we will use to catch GroupMe's POST messages to our callback URL).

You can do this by running the following commands in your terminal:

Expand All @@ -19,7 +19,7 @@ npm install express

This is the main script for DinoBot, which listens for messages in a GroupMe group and responds with dinosaur emojis based on certain triggers. The bot can respond to requests for dinos, mentions of its name, or random questions.

You can save this code in a file named `DinoBot.js`, and run it using Node.js with this commmand:
You can save this code in a file named `DinoBot.js`, and run it using Node.js with this command:

```bash
node DinoBot.js
Expand Down
2 changes: 1 addition & 1 deletion docs/examples/pingpong.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ Replies have a unique identifier called `base_reply_id`, which is the ID of the

The `mention` attachment allows you to mention a user in your bot's response. This is useful for drawing attention to the user who sent the original message. The `user_ids` array should contain the ID of the user you want to mention, and the `loci` array specifies the range of text that will be highlighted as a mention, where the first number is the start index and the second number is the length of the mention text.

For more information on how to use message attachements, see the [Attachments](../common/index.md#attachments) documentation.
For more information on how to use message attachments, see the [Attachments](../common/index.md#attachments) documentation.

## PingPong Bot Script

Expand Down
2 changes: 1 addition & 1 deletion mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ nav:
- Conversation Features:
- api/conversations/index.md
- Emoji Reactions: api/conversations/reactions.md
- Calandar Events: api/conversations/calendar.md
- Calendar Events: api/conversations/calendar.md
- Image Galleries: api/conversations/gallery.md
- Pinning Messages: api/conversations/pins.md
- Common Structures:
Expand Down