// Code generated by ent, DO NOT EDIT.

package apikey

import (
	"time"

	"entgo.io/ent/dialect/sql"
	"entgo.io/ent/dialect/sql/sqlgraph"
	"github.com/Wei-Shaw/sub2api/ent/predicate"
)

// ID filters vertices based on their ID field.
func ID(id int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldID, id))
}

// IDEQ applies the EQ predicate on the ID field.
func IDEQ(id int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldID, id))
}

// IDNEQ applies the NEQ predicate on the ID field.
func IDNEQ(id int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldID, id))
}

// IDIn applies the In predicate on the ID field.
func IDIn(ids ...int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldID, ids...))
}

// IDNotIn applies the NotIn predicate on the ID field.
func IDNotIn(ids ...int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldID, ids...))
}

// IDGT applies the GT predicate on the ID field.
func IDGT(id int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldID, id))
}

// IDGTE applies the GTE predicate on the ID field.
func IDGTE(id int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldID, id))
}

// IDLT applies the LT predicate on the ID field.
func IDLT(id int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldID, id))
}

// IDLTE applies the LTE predicate on the ID field.
func IDLTE(id int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldID, id))
}

// CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
func CreatedAt(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldCreatedAt, v))
}

// UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.
func UpdatedAt(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldUpdatedAt, v))
}

// DeletedAt applies equality check predicate on the "deleted_at" field. It's identical to DeletedAtEQ.
func DeletedAt(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldDeletedAt, v))
}

// UserID applies equality check predicate on the "user_id" field. It's identical to UserIDEQ.
func UserID(v int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldUserID, v))
}

// Key applies equality check predicate on the "key" field. It's identical to KeyEQ.
func Key(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldKey, v))
}

// Name applies equality check predicate on the "name" field. It's identical to NameEQ.
func Name(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldName, v))
}

// GroupID applies equality check predicate on the "group_id" field. It's identical to GroupIDEQ.
func GroupID(v int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldGroupID, v))
}

// Status applies equality check predicate on the "status" field. It's identical to StatusEQ.
func Status(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldStatus, v))
}

// LastUsedAt applies equality check predicate on the "last_used_at" field. It's identical to LastUsedAtEQ.
func LastUsedAt(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldLastUsedAt, v))
}

// Quota applies equality check predicate on the "quota" field. It's identical to QuotaEQ.
func Quota(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldQuota, v))
}

// QuotaUsed applies equality check predicate on the "quota_used" field. It's identical to QuotaUsedEQ.
func QuotaUsed(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldQuotaUsed, v))
}

// ExpiresAt applies equality check predicate on the "expires_at" field. It's identical to ExpiresAtEQ.
func ExpiresAt(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldExpiresAt, v))
}

// RateLimit5h applies equality check predicate on the "rate_limit_5h" field. It's identical to RateLimit5hEQ.
func RateLimit5h(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldRateLimit5h, v))
}

// RateLimit1d applies equality check predicate on the "rate_limit_1d" field. It's identical to RateLimit1dEQ.
func RateLimit1d(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldRateLimit1d, v))
}

// RateLimit7d applies equality check predicate on the "rate_limit_7d" field. It's identical to RateLimit7dEQ.
func RateLimit7d(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldRateLimit7d, v))
}

// Usage5h applies equality check predicate on the "usage_5h" field. It's identical to Usage5hEQ.
func Usage5h(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldUsage5h, v))
}

// Usage1d applies equality check predicate on the "usage_1d" field. It's identical to Usage1dEQ.
func Usage1d(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldUsage1d, v))
}

// Usage7d applies equality check predicate on the "usage_7d" field. It's identical to Usage7dEQ.
func Usage7d(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldUsage7d, v))
}

// Window5hStart applies equality check predicate on the "window_5h_start" field. It's identical to Window5hStartEQ.
func Window5hStart(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldWindow5hStart, v))
}

// Window1dStart applies equality check predicate on the "window_1d_start" field. It's identical to Window1dStartEQ.
func Window1dStart(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldWindow1dStart, v))
}

// Window7dStart applies equality check predicate on the "window_7d_start" field. It's identical to Window7dStartEQ.
func Window7dStart(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldWindow7dStart, v))
}

// CaptureRequests applies equality check predicate on the "capture_requests" field. It's identical to CaptureRequestsEQ.
func CaptureRequests(v bool) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldCaptureRequests, v))
}

// CreatedAtEQ applies the EQ predicate on the "created_at" field.
func CreatedAtEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldCreatedAt, v))
}

// CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
func CreatedAtNEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldCreatedAt, v))
}

// CreatedAtIn applies the In predicate on the "created_at" field.
func CreatedAtIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldCreatedAt, vs...))
}

// CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
func CreatedAtNotIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldCreatedAt, vs...))
}

// CreatedAtGT applies the GT predicate on the "created_at" field.
func CreatedAtGT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldCreatedAt, v))
}

// CreatedAtGTE applies the GTE predicate on the "created_at" field.
func CreatedAtGTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldCreatedAt, v))
}

// CreatedAtLT applies the LT predicate on the "created_at" field.
func CreatedAtLT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldCreatedAt, v))
}

// CreatedAtLTE applies the LTE predicate on the "created_at" field.
func CreatedAtLTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldCreatedAt, v))
}

// UpdatedAtEQ applies the EQ predicate on the "updated_at" field.
func UpdatedAtEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldUpdatedAt, v))
}

// UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.
func UpdatedAtNEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldUpdatedAt, v))
}

// UpdatedAtIn applies the In predicate on the "updated_at" field.
func UpdatedAtIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldUpdatedAt, vs...))
}

// UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.
func UpdatedAtNotIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldUpdatedAt, vs...))
}

// UpdatedAtGT applies the GT predicate on the "updated_at" field.
func UpdatedAtGT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldUpdatedAt, v))
}

// UpdatedAtGTE applies the GTE predicate on the "updated_at" field.
func UpdatedAtGTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldUpdatedAt, v))
}

// UpdatedAtLT applies the LT predicate on the "updated_at" field.
func UpdatedAtLT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldUpdatedAt, v))
}

// UpdatedAtLTE applies the LTE predicate on the "updated_at" field.
func UpdatedAtLTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldUpdatedAt, v))
}

// DeletedAtEQ applies the EQ predicate on the "deleted_at" field.
func DeletedAtEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldDeletedAt, v))
}

// DeletedAtNEQ applies the NEQ predicate on the "deleted_at" field.
func DeletedAtNEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldDeletedAt, v))
}

// DeletedAtIn applies the In predicate on the "deleted_at" field.
func DeletedAtIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldDeletedAt, vs...))
}

// DeletedAtNotIn applies the NotIn predicate on the "deleted_at" field.
func DeletedAtNotIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldDeletedAt, vs...))
}

// DeletedAtGT applies the GT predicate on the "deleted_at" field.
func DeletedAtGT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldDeletedAt, v))
}

// DeletedAtGTE applies the GTE predicate on the "deleted_at" field.
func DeletedAtGTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldDeletedAt, v))
}

// DeletedAtLT applies the LT predicate on the "deleted_at" field.
func DeletedAtLT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldDeletedAt, v))
}

// DeletedAtLTE applies the LTE predicate on the "deleted_at" field.
func DeletedAtLTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldDeletedAt, v))
}

// DeletedAtIsNil applies the IsNil predicate on the "deleted_at" field.
func DeletedAtIsNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldIsNull(FieldDeletedAt))
}

// DeletedAtNotNil applies the NotNil predicate on the "deleted_at" field.
func DeletedAtNotNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldNotNull(FieldDeletedAt))
}

// UserIDEQ applies the EQ predicate on the "user_id" field.
func UserIDEQ(v int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldUserID, v))
}

// UserIDNEQ applies the NEQ predicate on the "user_id" field.
func UserIDNEQ(v int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldUserID, v))
}

// UserIDIn applies the In predicate on the "user_id" field.
func UserIDIn(vs ...int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldUserID, vs...))
}

// UserIDNotIn applies the NotIn predicate on the "user_id" field.
func UserIDNotIn(vs ...int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldUserID, vs...))
}

// KeyEQ applies the EQ predicate on the "key" field.
func KeyEQ(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldKey, v))
}

// KeyNEQ applies the NEQ predicate on the "key" field.
func KeyNEQ(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldKey, v))
}

// KeyIn applies the In predicate on the "key" field.
func KeyIn(vs ...string) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldKey, vs...))
}

// KeyNotIn applies the NotIn predicate on the "key" field.
func KeyNotIn(vs ...string) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldKey, vs...))
}

// KeyGT applies the GT predicate on the "key" field.
func KeyGT(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldKey, v))
}

// KeyGTE applies the GTE predicate on the "key" field.
func KeyGTE(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldKey, v))
}

// KeyLT applies the LT predicate on the "key" field.
func KeyLT(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldKey, v))
}

// KeyLTE applies the LTE predicate on the "key" field.
func KeyLTE(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldKey, v))
}

// KeyContains applies the Contains predicate on the "key" field.
func KeyContains(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldContains(FieldKey, v))
}

// KeyHasPrefix applies the HasPrefix predicate on the "key" field.
func KeyHasPrefix(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldHasPrefix(FieldKey, v))
}

// KeyHasSuffix applies the HasSuffix predicate on the "key" field.
func KeyHasSuffix(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldHasSuffix(FieldKey, v))
}

// KeyEqualFold applies the EqualFold predicate on the "key" field.
func KeyEqualFold(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldEqualFold(FieldKey, v))
}

// KeyContainsFold applies the ContainsFold predicate on the "key" field.
func KeyContainsFold(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldContainsFold(FieldKey, v))
}

// NameEQ applies the EQ predicate on the "name" field.
func NameEQ(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldName, v))
}

// NameNEQ applies the NEQ predicate on the "name" field.
func NameNEQ(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldName, v))
}

// NameIn applies the In predicate on the "name" field.
func NameIn(vs ...string) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldName, vs...))
}

// NameNotIn applies the NotIn predicate on the "name" field.
func NameNotIn(vs ...string) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldName, vs...))
}

// NameGT applies the GT predicate on the "name" field.
func NameGT(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldName, v))
}

// NameGTE applies the GTE predicate on the "name" field.
func NameGTE(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldName, v))
}

// NameLT applies the LT predicate on the "name" field.
func NameLT(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldName, v))
}

// NameLTE applies the LTE predicate on the "name" field.
func NameLTE(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldName, v))
}

// NameContains applies the Contains predicate on the "name" field.
func NameContains(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldContains(FieldName, v))
}

// NameHasPrefix applies the HasPrefix predicate on the "name" field.
func NameHasPrefix(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldHasPrefix(FieldName, v))
}

// NameHasSuffix applies the HasSuffix predicate on the "name" field.
func NameHasSuffix(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldHasSuffix(FieldName, v))
}

// NameEqualFold applies the EqualFold predicate on the "name" field.
func NameEqualFold(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldEqualFold(FieldName, v))
}

// NameContainsFold applies the ContainsFold predicate on the "name" field.
func NameContainsFold(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldContainsFold(FieldName, v))
}

// GroupIDEQ applies the EQ predicate on the "group_id" field.
func GroupIDEQ(v int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldGroupID, v))
}

// GroupIDNEQ applies the NEQ predicate on the "group_id" field.
func GroupIDNEQ(v int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldGroupID, v))
}

// GroupIDIn applies the In predicate on the "group_id" field.
func GroupIDIn(vs ...int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldGroupID, vs...))
}

// GroupIDNotIn applies the NotIn predicate on the "group_id" field.
func GroupIDNotIn(vs ...int64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldGroupID, vs...))
}

// GroupIDIsNil applies the IsNil predicate on the "group_id" field.
func GroupIDIsNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldIsNull(FieldGroupID))
}

// GroupIDNotNil applies the NotNil predicate on the "group_id" field.
func GroupIDNotNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldNotNull(FieldGroupID))
}

// StatusEQ applies the EQ predicate on the "status" field.
func StatusEQ(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldStatus, v))
}

// StatusNEQ applies the NEQ predicate on the "status" field.
func StatusNEQ(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldStatus, v))
}

// StatusIn applies the In predicate on the "status" field.
func StatusIn(vs ...string) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldStatus, vs...))
}

// StatusNotIn applies the NotIn predicate on the "status" field.
func StatusNotIn(vs ...string) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldStatus, vs...))
}

// StatusGT applies the GT predicate on the "status" field.
func StatusGT(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldStatus, v))
}

// StatusGTE applies the GTE predicate on the "status" field.
func StatusGTE(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldStatus, v))
}

// StatusLT applies the LT predicate on the "status" field.
func StatusLT(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldStatus, v))
}

// StatusLTE applies the LTE predicate on the "status" field.
func StatusLTE(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldStatus, v))
}

// StatusContains applies the Contains predicate on the "status" field.
func StatusContains(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldContains(FieldStatus, v))
}

// StatusHasPrefix applies the HasPrefix predicate on the "status" field.
func StatusHasPrefix(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldHasPrefix(FieldStatus, v))
}

// StatusHasSuffix applies the HasSuffix predicate on the "status" field.
func StatusHasSuffix(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldHasSuffix(FieldStatus, v))
}

// StatusEqualFold applies the EqualFold predicate on the "status" field.
func StatusEqualFold(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldEqualFold(FieldStatus, v))
}

// StatusContainsFold applies the ContainsFold predicate on the "status" field.
func StatusContainsFold(v string) predicate.APIKey {
	return predicate.APIKey(sql.FieldContainsFold(FieldStatus, v))
}

// LastUsedAtEQ applies the EQ predicate on the "last_used_at" field.
func LastUsedAtEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldLastUsedAt, v))
}

// LastUsedAtNEQ applies the NEQ predicate on the "last_used_at" field.
func LastUsedAtNEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldLastUsedAt, v))
}

// LastUsedAtIn applies the In predicate on the "last_used_at" field.
func LastUsedAtIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldLastUsedAt, vs...))
}

// LastUsedAtNotIn applies the NotIn predicate on the "last_used_at" field.
func LastUsedAtNotIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldLastUsedAt, vs...))
}

// LastUsedAtGT applies the GT predicate on the "last_used_at" field.
func LastUsedAtGT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldLastUsedAt, v))
}

// LastUsedAtGTE applies the GTE predicate on the "last_used_at" field.
func LastUsedAtGTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldLastUsedAt, v))
}

// LastUsedAtLT applies the LT predicate on the "last_used_at" field.
func LastUsedAtLT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldLastUsedAt, v))
}

// LastUsedAtLTE applies the LTE predicate on the "last_used_at" field.
func LastUsedAtLTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldLastUsedAt, v))
}

// LastUsedAtIsNil applies the IsNil predicate on the "last_used_at" field.
func LastUsedAtIsNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldIsNull(FieldLastUsedAt))
}

// LastUsedAtNotNil applies the NotNil predicate on the "last_used_at" field.
func LastUsedAtNotNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldNotNull(FieldLastUsedAt))
}

// IPWhitelistIsNil applies the IsNil predicate on the "ip_whitelist" field.
func IPWhitelistIsNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldIsNull(FieldIPWhitelist))
}

// IPWhitelistNotNil applies the NotNil predicate on the "ip_whitelist" field.
func IPWhitelistNotNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldNotNull(FieldIPWhitelist))
}

// IPBlacklistIsNil applies the IsNil predicate on the "ip_blacklist" field.
func IPBlacklistIsNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldIsNull(FieldIPBlacklist))
}

// IPBlacklistNotNil applies the NotNil predicate on the "ip_blacklist" field.
func IPBlacklistNotNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldNotNull(FieldIPBlacklist))
}

// QuotaEQ applies the EQ predicate on the "quota" field.
func QuotaEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldQuota, v))
}

// QuotaNEQ applies the NEQ predicate on the "quota" field.
func QuotaNEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldQuota, v))
}

// QuotaIn applies the In predicate on the "quota" field.
func QuotaIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldQuota, vs...))
}

// QuotaNotIn applies the NotIn predicate on the "quota" field.
func QuotaNotIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldQuota, vs...))
}

// QuotaGT applies the GT predicate on the "quota" field.
func QuotaGT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldQuota, v))
}

// QuotaGTE applies the GTE predicate on the "quota" field.
func QuotaGTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldQuota, v))
}

// QuotaLT applies the LT predicate on the "quota" field.
func QuotaLT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldQuota, v))
}

// QuotaLTE applies the LTE predicate on the "quota" field.
func QuotaLTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldQuota, v))
}

// QuotaUsedEQ applies the EQ predicate on the "quota_used" field.
func QuotaUsedEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldQuotaUsed, v))
}

// QuotaUsedNEQ applies the NEQ predicate on the "quota_used" field.
func QuotaUsedNEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldQuotaUsed, v))
}

// QuotaUsedIn applies the In predicate on the "quota_used" field.
func QuotaUsedIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldQuotaUsed, vs...))
}

// QuotaUsedNotIn applies the NotIn predicate on the "quota_used" field.
func QuotaUsedNotIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldQuotaUsed, vs...))
}

// QuotaUsedGT applies the GT predicate on the "quota_used" field.
func QuotaUsedGT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldQuotaUsed, v))
}

// QuotaUsedGTE applies the GTE predicate on the "quota_used" field.
func QuotaUsedGTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldQuotaUsed, v))
}

// QuotaUsedLT applies the LT predicate on the "quota_used" field.
func QuotaUsedLT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldQuotaUsed, v))
}

// QuotaUsedLTE applies the LTE predicate on the "quota_used" field.
func QuotaUsedLTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldQuotaUsed, v))
}

// ExpiresAtEQ applies the EQ predicate on the "expires_at" field.
func ExpiresAtEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldExpiresAt, v))
}

// ExpiresAtNEQ applies the NEQ predicate on the "expires_at" field.
func ExpiresAtNEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldExpiresAt, v))
}

// ExpiresAtIn applies the In predicate on the "expires_at" field.
func ExpiresAtIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldExpiresAt, vs...))
}

// ExpiresAtNotIn applies the NotIn predicate on the "expires_at" field.
func ExpiresAtNotIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldExpiresAt, vs...))
}

// ExpiresAtGT applies the GT predicate on the "expires_at" field.
func ExpiresAtGT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldExpiresAt, v))
}

// ExpiresAtGTE applies the GTE predicate on the "expires_at" field.
func ExpiresAtGTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldExpiresAt, v))
}

// ExpiresAtLT applies the LT predicate on the "expires_at" field.
func ExpiresAtLT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldExpiresAt, v))
}

// ExpiresAtLTE applies the LTE predicate on the "expires_at" field.
func ExpiresAtLTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldExpiresAt, v))
}

// ExpiresAtIsNil applies the IsNil predicate on the "expires_at" field.
func ExpiresAtIsNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldIsNull(FieldExpiresAt))
}

// ExpiresAtNotNil applies the NotNil predicate on the "expires_at" field.
func ExpiresAtNotNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldNotNull(FieldExpiresAt))
}

// RateLimit5hEQ applies the EQ predicate on the "rate_limit_5h" field.
func RateLimit5hEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldRateLimit5h, v))
}

// RateLimit5hNEQ applies the NEQ predicate on the "rate_limit_5h" field.
func RateLimit5hNEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldRateLimit5h, v))
}

// RateLimit5hIn applies the In predicate on the "rate_limit_5h" field.
func RateLimit5hIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldRateLimit5h, vs...))
}

// RateLimit5hNotIn applies the NotIn predicate on the "rate_limit_5h" field.
func RateLimit5hNotIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldRateLimit5h, vs...))
}

// RateLimit5hGT applies the GT predicate on the "rate_limit_5h" field.
func RateLimit5hGT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldRateLimit5h, v))
}

// RateLimit5hGTE applies the GTE predicate on the "rate_limit_5h" field.
func RateLimit5hGTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldRateLimit5h, v))
}

// RateLimit5hLT applies the LT predicate on the "rate_limit_5h" field.
func RateLimit5hLT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldRateLimit5h, v))
}

// RateLimit5hLTE applies the LTE predicate on the "rate_limit_5h" field.
func RateLimit5hLTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldRateLimit5h, v))
}

// RateLimit1dEQ applies the EQ predicate on the "rate_limit_1d" field.
func RateLimit1dEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldRateLimit1d, v))
}

// RateLimit1dNEQ applies the NEQ predicate on the "rate_limit_1d" field.
func RateLimit1dNEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldRateLimit1d, v))
}

// RateLimit1dIn applies the In predicate on the "rate_limit_1d" field.
func RateLimit1dIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldRateLimit1d, vs...))
}

// RateLimit1dNotIn applies the NotIn predicate on the "rate_limit_1d" field.
func RateLimit1dNotIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldRateLimit1d, vs...))
}

// RateLimit1dGT applies the GT predicate on the "rate_limit_1d" field.
func RateLimit1dGT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldRateLimit1d, v))
}

// RateLimit1dGTE applies the GTE predicate on the "rate_limit_1d" field.
func RateLimit1dGTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldRateLimit1d, v))
}

// RateLimit1dLT applies the LT predicate on the "rate_limit_1d" field.
func RateLimit1dLT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldRateLimit1d, v))
}

// RateLimit1dLTE applies the LTE predicate on the "rate_limit_1d" field.
func RateLimit1dLTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldRateLimit1d, v))
}

// RateLimit7dEQ applies the EQ predicate on the "rate_limit_7d" field.
func RateLimit7dEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldRateLimit7d, v))
}

// RateLimit7dNEQ applies the NEQ predicate on the "rate_limit_7d" field.
func RateLimit7dNEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldRateLimit7d, v))
}

// RateLimit7dIn applies the In predicate on the "rate_limit_7d" field.
func RateLimit7dIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldRateLimit7d, vs...))
}

// RateLimit7dNotIn applies the NotIn predicate on the "rate_limit_7d" field.
func RateLimit7dNotIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldRateLimit7d, vs...))
}

// RateLimit7dGT applies the GT predicate on the "rate_limit_7d" field.
func RateLimit7dGT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldRateLimit7d, v))
}

// RateLimit7dGTE applies the GTE predicate on the "rate_limit_7d" field.
func RateLimit7dGTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldRateLimit7d, v))
}

// RateLimit7dLT applies the LT predicate on the "rate_limit_7d" field.
func RateLimit7dLT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldRateLimit7d, v))
}

// RateLimit7dLTE applies the LTE predicate on the "rate_limit_7d" field.
func RateLimit7dLTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldRateLimit7d, v))
}

// Usage5hEQ applies the EQ predicate on the "usage_5h" field.
func Usage5hEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldUsage5h, v))
}

// Usage5hNEQ applies the NEQ predicate on the "usage_5h" field.
func Usage5hNEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldUsage5h, v))
}

// Usage5hIn applies the In predicate on the "usage_5h" field.
func Usage5hIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldUsage5h, vs...))
}

// Usage5hNotIn applies the NotIn predicate on the "usage_5h" field.
func Usage5hNotIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldUsage5h, vs...))
}

// Usage5hGT applies the GT predicate on the "usage_5h" field.
func Usage5hGT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldUsage5h, v))
}

// Usage5hGTE applies the GTE predicate on the "usage_5h" field.
func Usage5hGTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldUsage5h, v))
}

// Usage5hLT applies the LT predicate on the "usage_5h" field.
func Usage5hLT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldUsage5h, v))
}

// Usage5hLTE applies the LTE predicate on the "usage_5h" field.
func Usage5hLTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldUsage5h, v))
}

// Usage1dEQ applies the EQ predicate on the "usage_1d" field.
func Usage1dEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldUsage1d, v))
}

// Usage1dNEQ applies the NEQ predicate on the "usage_1d" field.
func Usage1dNEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldUsage1d, v))
}

// Usage1dIn applies the In predicate on the "usage_1d" field.
func Usage1dIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldUsage1d, vs...))
}

// Usage1dNotIn applies the NotIn predicate on the "usage_1d" field.
func Usage1dNotIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldUsage1d, vs...))
}

// Usage1dGT applies the GT predicate on the "usage_1d" field.
func Usage1dGT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldUsage1d, v))
}

// Usage1dGTE applies the GTE predicate on the "usage_1d" field.
func Usage1dGTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldUsage1d, v))
}

// Usage1dLT applies the LT predicate on the "usage_1d" field.
func Usage1dLT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldUsage1d, v))
}

// Usage1dLTE applies the LTE predicate on the "usage_1d" field.
func Usage1dLTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldUsage1d, v))
}

// Usage7dEQ applies the EQ predicate on the "usage_7d" field.
func Usage7dEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldUsage7d, v))
}

// Usage7dNEQ applies the NEQ predicate on the "usage_7d" field.
func Usage7dNEQ(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldUsage7d, v))
}

// Usage7dIn applies the In predicate on the "usage_7d" field.
func Usage7dIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldUsage7d, vs...))
}

// Usage7dNotIn applies the NotIn predicate on the "usage_7d" field.
func Usage7dNotIn(vs ...float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldUsage7d, vs...))
}

// Usage7dGT applies the GT predicate on the "usage_7d" field.
func Usage7dGT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldUsage7d, v))
}

// Usage7dGTE applies the GTE predicate on the "usage_7d" field.
func Usage7dGTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldUsage7d, v))
}

// Usage7dLT applies the LT predicate on the "usage_7d" field.
func Usage7dLT(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldUsage7d, v))
}

// Usage7dLTE applies the LTE predicate on the "usage_7d" field.
func Usage7dLTE(v float64) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldUsage7d, v))
}

// Window5hStartEQ applies the EQ predicate on the "window_5h_start" field.
func Window5hStartEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldWindow5hStart, v))
}

// Window5hStartNEQ applies the NEQ predicate on the "window_5h_start" field.
func Window5hStartNEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldWindow5hStart, v))
}

// Window5hStartIn applies the In predicate on the "window_5h_start" field.
func Window5hStartIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldWindow5hStart, vs...))
}

// Window5hStartNotIn applies the NotIn predicate on the "window_5h_start" field.
func Window5hStartNotIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldWindow5hStart, vs...))
}

// Window5hStartGT applies the GT predicate on the "window_5h_start" field.
func Window5hStartGT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldWindow5hStart, v))
}

// Window5hStartGTE applies the GTE predicate on the "window_5h_start" field.
func Window5hStartGTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldWindow5hStart, v))
}

// Window5hStartLT applies the LT predicate on the "window_5h_start" field.
func Window5hStartLT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldWindow5hStart, v))
}

// Window5hStartLTE applies the LTE predicate on the "window_5h_start" field.
func Window5hStartLTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldWindow5hStart, v))
}

// Window5hStartIsNil applies the IsNil predicate on the "window_5h_start" field.
func Window5hStartIsNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldIsNull(FieldWindow5hStart))
}

// Window5hStartNotNil applies the NotNil predicate on the "window_5h_start" field.
func Window5hStartNotNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldNotNull(FieldWindow5hStart))
}

// Window1dStartEQ applies the EQ predicate on the "window_1d_start" field.
func Window1dStartEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldWindow1dStart, v))
}

// Window1dStartNEQ applies the NEQ predicate on the "window_1d_start" field.
func Window1dStartNEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldWindow1dStart, v))
}

// Window1dStartIn applies the In predicate on the "window_1d_start" field.
func Window1dStartIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldWindow1dStart, vs...))
}

// Window1dStartNotIn applies the NotIn predicate on the "window_1d_start" field.
func Window1dStartNotIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldWindow1dStart, vs...))
}

// Window1dStartGT applies the GT predicate on the "window_1d_start" field.
func Window1dStartGT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldWindow1dStart, v))
}

// Window1dStartGTE applies the GTE predicate on the "window_1d_start" field.
func Window1dStartGTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldWindow1dStart, v))
}

// Window1dStartLT applies the LT predicate on the "window_1d_start" field.
func Window1dStartLT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldWindow1dStart, v))
}

// Window1dStartLTE applies the LTE predicate on the "window_1d_start" field.
func Window1dStartLTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldWindow1dStart, v))
}

// Window1dStartIsNil applies the IsNil predicate on the "window_1d_start" field.
func Window1dStartIsNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldIsNull(FieldWindow1dStart))
}

// Window1dStartNotNil applies the NotNil predicate on the "window_1d_start" field.
func Window1dStartNotNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldNotNull(FieldWindow1dStart))
}

// Window7dStartEQ applies the EQ predicate on the "window_7d_start" field.
func Window7dStartEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldWindow7dStart, v))
}

// Window7dStartNEQ applies the NEQ predicate on the "window_7d_start" field.
func Window7dStartNEQ(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldWindow7dStart, v))
}

// Window7dStartIn applies the In predicate on the "window_7d_start" field.
func Window7dStartIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldIn(FieldWindow7dStart, vs...))
}

// Window7dStartNotIn applies the NotIn predicate on the "window_7d_start" field.
func Window7dStartNotIn(vs ...time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldNotIn(FieldWindow7dStart, vs...))
}

// Window7dStartGT applies the GT predicate on the "window_7d_start" field.
func Window7dStartGT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGT(FieldWindow7dStart, v))
}

// Window7dStartGTE applies the GTE predicate on the "window_7d_start" field.
func Window7dStartGTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldGTE(FieldWindow7dStart, v))
}

// Window7dStartLT applies the LT predicate on the "window_7d_start" field.
func Window7dStartLT(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLT(FieldWindow7dStart, v))
}

// Window7dStartLTE applies the LTE predicate on the "window_7d_start" field.
func Window7dStartLTE(v time.Time) predicate.APIKey {
	return predicate.APIKey(sql.FieldLTE(FieldWindow7dStart, v))
}

// Window7dStartIsNil applies the IsNil predicate on the "window_7d_start" field.
func Window7dStartIsNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldIsNull(FieldWindow7dStart))
}

// Window7dStartNotNil applies the NotNil predicate on the "window_7d_start" field.
func Window7dStartNotNil() predicate.APIKey {
	return predicate.APIKey(sql.FieldNotNull(FieldWindow7dStart))
}

// CaptureRequestsEQ applies the EQ predicate on the "capture_requests" field.
func CaptureRequestsEQ(v bool) predicate.APIKey {
	return predicate.APIKey(sql.FieldEQ(FieldCaptureRequests, v))
}

// CaptureRequestsNEQ applies the NEQ predicate on the "capture_requests" field.
func CaptureRequestsNEQ(v bool) predicate.APIKey {
	return predicate.APIKey(sql.FieldNEQ(FieldCaptureRequests, v))
}

// HasUser applies the HasEdge predicate on the "user" edge.
func HasUser() predicate.APIKey {
	return predicate.APIKey(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.M2O, true, UserTable, UserColumn),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasUserWith applies the HasEdge predicate on the "user" edge with a given conditions (other predicates).
func HasUserWith(preds ...predicate.User) predicate.APIKey {
	return predicate.APIKey(func(s *sql.Selector) {
		step := newUserStep()
		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
			for _, p := range preds {
				p(s)
			}
		})
	})
}

// HasGroup applies the HasEdge predicate on the "group" edge.
func HasGroup() predicate.APIKey {
	return predicate.APIKey(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.M2O, true, GroupTable, GroupColumn),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasGroupWith applies the HasEdge predicate on the "group" edge with a given conditions (other predicates).
func HasGroupWith(preds ...predicate.Group) predicate.APIKey {
	return predicate.APIKey(func(s *sql.Selector) {
		step := newGroupStep()
		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
			for _, p := range preds {
				p(s)
			}
		})
	})
}

// HasUsageLogs applies the HasEdge predicate on the "usage_logs" edge.
func HasUsageLogs() predicate.APIKey {
	return predicate.APIKey(func(s *sql.Selector) {
		step := sqlgraph.NewStep(
			sqlgraph.From(Table, FieldID),
			sqlgraph.Edge(sqlgraph.O2M, false, UsageLogsTable, UsageLogsColumn),
		)
		sqlgraph.HasNeighbors(s, step)
	})
}

// HasUsageLogsWith applies the HasEdge predicate on the "usage_logs" edge with a given conditions (other predicates).
func HasUsageLogsWith(preds ...predicate.UsageLog) predicate.APIKey {
	return predicate.APIKey(func(s *sql.Selector) {
		step := newUsageLogsStep()
		sqlgraph.HasNeighborsWith(s, step, func(s *sql.Selector) {
			for _, p := range preds {
				p(s)
			}
		})
	})
}

// And groups predicates with the AND operator between them.
func And(predicates ...predicate.APIKey) predicate.APIKey {
	return predicate.APIKey(sql.AndPredicates(predicates...))
}

// Or groups predicates with the OR operator between them.
func Or(predicates ...predicate.APIKey) predicate.APIKey {
	return predicate.APIKey(sql.OrPredicates(predicates...))
}

// Not applies the not operator on the given predicate.
func Not(p predicate.APIKey) predicate.APIKey {
	return predicate.APIKey(sql.NotPredicates(p))
}
