Package discord4j.core.spec.legacy
Class LegacyAuditLogQuerySpec
java.lang.Object
discord4j.core.spec.legacy.LegacyAuditLogQuerySpec
- All Implemented Interfaces:
LegacySpec<Map<String,
Object>>
A spec used to query audit log entries that match the specified filter.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionsetActionType
(ActionType actionType) Sets the query to return entries where the action type is the same as the one provided.Sets the query to return entries before a certain entry id.setLimit
(int limit) Sets the query to return a max of entries.setResponsibleUser
(Snowflake userId) Sets the query to only return entries where the user specified is responsible for the action.
-
Constructor Details
-
LegacyAuditLogQuerySpec
public LegacyAuditLogQuerySpec()
-
-
Method Details
-
setResponsibleUser
Sets the query to only return entries where the user specified is responsible for the action.- Parameters:
userId
- TheSnowflake
of the responsible user to filter by.- Returns:
- This spec.
-
setActionType
Sets the query to return entries where the action type is the same as the one provided.- Parameters:
actionType
- TheActionType
of the audit log entries to filter by.- Returns:
- This spec.
-
setBefore
Sets the query to return entries before a certain entry id.- Parameters:
beforeId
- TheSnowflake
of the audit log id to filter by before of.- Returns:
- This spec.
-
setLimit
Sets the query to return a max of entries.- Parameters:
limit
- The limit of the audit log entries to filter by.- Returns:
- This spec.
-
asRequest
- Specified by:
asRequest
in interfaceLegacySpec<Map<String,
Object>>
-