-
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(
GET /api/chatrooms/{address}
): add missing params
- Loading branch information
Showing
8 changed files
with
87 additions
and
2 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,7 +1,54 @@ | ||
############################### | ||
######## Path params ########## | ||
############################### | ||
|
||
- name: address | ||
in: path | ||
description: ADAMANT address | ||
required: true | ||
schema: | ||
type: string | ||
example: U839357947177758191 | ||
|
||
############################### | ||
####### Common filters ######## | ||
############################### | ||
|
||
# senderId | ||
- $ref: '../../common/params/filters/senderId/senderId.yaml' | ||
- $ref: '../../common/params/filters/senderId/andSenderId.yaml' | ||
- $ref: '../../common/params/filters/senderId/orSenderId.yaml' | ||
|
||
# recipientId | ||
- $ref: '../../common/params/filters/recipientId/recipientId.yaml' | ||
- $ref: '../../common/params/filters/recipientId/andRecipientId.yaml' | ||
- $ref: '../../common/params/filters/recipientId/orRecipientId.yaml' | ||
|
||
############################### | ||
######## Common params ######## | ||
############################### | ||
|
||
# offset | ||
- $ref: '../../common/params/offset.yaml' | ||
|
||
# orderBy | ||
- $ref: '../../common/params/orderBy.yaml' | ||
|
||
############################### | ||
## Endpoint specific filters ## | ||
############################### | ||
|
||
# userId | ||
- $ref: './params/filters/userId/userId.yaml' | ||
- $ref: './params/filters/userId/andUserId.yaml' | ||
- $ref: './params/filters/userId/orUserId.yaml' | ||
|
||
# withoutDirectTransfers | ||
- $ref: './params/filters/withoutDirectTransfers/withoutDirectTransfers.yaml' | ||
|
||
############################### | ||
### Endpoint specific params ## | ||
############################### | ||
|
||
# limit | ||
- $ref: './params/limit.yaml' |
8 changes: 8 additions & 0 deletions
8
specification/chats/GetChatRooms/params/filters/userId/andUserId.yaml
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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
name: and:userId | ||
in: query | ||
description: | | ||
Filter by senderId/recipientId (`and` operator). | ||
The query will look like `tx.senderId = {userId} OR tx.recipientId = {userId}`. | ||
schema: | ||
type: string | ||
required: false |
8 changes: 8 additions & 0 deletions
8
specification/chats/GetChatRooms/params/filters/userId/orUserId.yaml
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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
name: or:userId | ||
in: query | ||
description: | | ||
Filter by senderId/recipientId (`or` operator). | ||
The query will look like `tx.senderId = {userId} OR tx.recipientId = {userId}`. | ||
schema: | ||
type: string | ||
required: false |
9 changes: 9 additions & 0 deletions
9
specification/chats/GetChatRooms/params/filters/userId/userId.yaml
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
name: userId | ||
in: query | ||
description: | | ||
Filter by senderId/recipientId. | ||
The query will look like `tx.senderId = {userId} OR tx.recipientId = {userId}`. | ||
schema: | ||
type: string | ||
example: U14236667426471084862 | ||
required: false |
7 changes: 7 additions & 0 deletions
7
...tion/chats/GetChatRooms/params/filters/withoutDirectTransfers/withoutDirectTransfers.yaml
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
name: withoutDirectTransfers | ||
in: query | ||
description: When set to `true`, excludes type `0` transactions (direct token transfers) from results. Default is `false`. | ||
schema: | ||
type: boolean | ||
default: false | ||
required: false |
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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
name: limit | ||
in: query | ||
description: Limit number of transactions in the result | ||
schema: | ||
type: integer | ||
example: 10 | ||
default: 25 | ||
required: false |
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 |
---|---|---|
|
@@ -3,5 +3,4 @@ in: query | |
description: Filter by recipientId | ||
schema: | ||
type: string | ||
example: U18132012621449491414 | ||
required: false |
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 |
---|---|---|
|
@@ -3,5 +3,4 @@ in: query | |
description: Filter by senderId | ||
schema: | ||
type: string | ||
example: U14236667426471084862 | ||
required: false |