Skip to content

Commit

Permalink
Merge pull request #108 from TogetherCrew/107-add-new-field-to-rawinf…
Browse files Browse the repository at this point in the history
…o-schema-to-track-webhook-messages

[FEATURE]: add isGeneratedByWebhook field
  • Loading branch information
cyri113 authored Sep 15, 2023
2 parents 713a47e + 28e5f68 commit 28932ba
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 1 deletion.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ rawinfo {
channelName: string | null,
threadId: Snowflake | null,
threadName: string | null,
isGeneratedByWebhook: boolean
}
```

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@togethercrew.dev/db",
"version": "2.4.99",
"version": "2.5.00",
"description": "All interactions with DB",
"main": "./dist/index.js",
"types": "./dist/index.d.ts",
Expand Down
2 changes: 2 additions & 0 deletions src/interfaces/RawInfo.interface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ export interface IRawInfo {
channelName: string | null;
threadId: Snowflake | null;
threadName: string | null;
isGeneratedByWebhook?: boolean;
}

export interface IRawInfoUpdateBody {
Expand All @@ -23,6 +24,7 @@ export interface IRawInfoUpdateBody {
threadId?: Snowflake | null;
threadName?: string | null;
content?: string;
isGeneratedByWebhook: boolean;
}

export interface RawInfoModel extends Model<IRawInfo> {
Expand Down
3 changes: 3 additions & 0 deletions src/models/schemas/RawInfo.schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ const rawInfoSchema = new Schema<IRawInfo>({
threadName: {
type: String,
},
isGeneratedByWebhook: {
type: Boolean,
},
});

// Plugins
Expand Down

0 comments on commit 28932ba

Please sign in to comment.