-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update readme and improve error handling
- Loading branch information
Showing
3 changed files
with
48 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,24 @@ | ||
# social-links-bot | ||
# social-links-bot | ||
|
||
A Devvit app that responds to user lists and returns their social links (if any). | ||
|
||
Object type returned is an array of the following type: | ||
|
||
```ts | ||
interface UserSocialLinks { | ||
username?: string; | ||
error?: string; | ||
errorDetail?: string; | ||
socialLinks?: UserSocialLink[]; | ||
} | ||
``` | ||
|
||
Input is in the form of a JSON array of string e.g. `["user1", "user2"]`. Usernames are not case sensitive. | ||
|
||
If all is well, the error/errorDetail attributes are omitted. | ||
|
||
If the input is badly formed (e.g. not JSON, not a string array, containing entries that are impossible usernames (too short/long), or contains duplicate items), `error` and `errorDetail` attributes are returned in a single array item. | ||
|
||
Otherwise, an array of usernames with their social links (if any) is returned. | ||
|
||
Shadowbanned, suspended and deleted users cannot be retrieved, in which case their username and an error of "SHADOWBANNED" is returned. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
name: social-links-bot | ||
version: 0.0.14 | ||
version: 0.0.17 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters