feature: support X-RateLimit-Reset-After (#1372)
* feature: support X-RateLimit-Reset-After
Users may now optionally disable using the system clock to calculate
the ratelimit duration. This may be overrided globally, via
DiscordConfig, or per RequestOptions.
This change has been built and tested via the integrated test suite,
but has not been tested in the real world. Please verify this does not
break any of the edge-case ratelimits.
* patch: wire new config properties to ApiClient
* patch: update Reset-After parsing precision
This patch applies the changes made to parsing precision in 606dac3.
This commit is contained in:
@@ -44,6 +44,18 @@ namespace Discord
|
||||
/// to all actions.
|
||||
/// </remarks>
|
||||
public string AuditLogReason { get; set; }
|
||||
/// <summary>
|
||||
/// Gets or sets whether or not this request should use the system
|
||||
/// clock for rate-limiting. Defaults to <c>true</c>.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// This property can also be set in <see cref="DiscordConfig">.
|
||||
///
|
||||
/// On a per-request basis, the system clock should only be disabled
|
||||
/// when millisecond precision is especially important, and the
|
||||
/// hosting system is known to have a desynced clock.
|
||||
/// </remarks>
|
||||
public bool? UseSystemClock { get; set; }
|
||||
|
||||
internal bool IgnoreState { get; set; }
|
||||
internal string BucketId { get; set; }
|
||||
|
||||
Reference in New Issue
Block a user