Skip to content

Commit

Permalink
Automated SDK update
Browse files Browse the repository at this point in the history
This updates the SDK from internal repo commit segmentio/public-api@c1f20b66.
  • Loading branch information
APIs and Common Services team committed Dec 9, 2024
1 parent 00edf51 commit 89c197c
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,15 @@ class CreateSourceRegulationV1Input(BaseModel):
@validator('regulation_type')
def regulation_type_validate_enum(cls, value):
"""Validates the enum"""
if value not in ('DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS'):
raise ValueError("must be one of enum values ('DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS')")
if value not in ('DELETE_ARCHIVE_ONLY', 'DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS'):
raise ValueError("must be one of enum values ('DELETE_ARCHIVE_ONLY', 'DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS')")
return value

@validator('subject_type')
def subject_type_validate_enum(cls, value):
"""Validates the enum"""
if value not in ('USER_ID'):
raise ValueError("must be one of enum values ('USER_ID')")
if value not in ('ANONYMOUS_ID', 'USER_ID'):
raise ValueError("must be one of enum values ('ANONYMOUS_ID', 'USER_ID')")
return value

class Config:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,15 @@ class CreateWorkspaceRegulationV1Input(BaseModel):
@validator('regulation_type')
def regulation_type_validate_enum(cls, value):
"""Validates the enum"""
if value not in ('DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS'):
raise ValueError("must be one of enum values ('DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS')")
if value not in ('DELETE_ARCHIVE_ONLY', 'DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS'):
raise ValueError("must be one of enum values ('DELETE_ARCHIVE_ONLY', 'DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS')")
return value

@validator('subject_type')
def subject_type_validate_enum(cls, value):
"""Validates the enum"""
if value not in ('OBJECT_ID', 'USER_ID'):
raise ValueError("must be one of enum values ('OBJECT_ID', 'USER_ID')")
if value not in ('ANONYMOUS_ID', 'OBJECT_ID', 'USER_ID'):
raise ValueError("must be one of enum values ('ANONYMOUS_ID', 'OBJECT_ID', 'USER_ID')")
return value

class Config:
Expand Down
4 changes: 2 additions & 2 deletions segment_public_api/models/regulation_list_entry_v1.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ def status_validate_enum(cls, value):
@validator('regulation_type')
def regulation_type_validate_enum(cls, value):
"""Validates the enum"""
if value not in ('DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS'):
raise ValueError("must be one of enum values ('DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS')")
if value not in ('DELETE_ARCHIVE_ONLY', 'DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS'):
raise ValueError("must be one of enum values ('DELETE_ARCHIVE_ONLY', 'DELETE_INTERNAL', 'DELETE_ONLY', 'SUPPRESS_ONLY', 'SUPPRESS_WITH_DELETE', 'SUPPRESS_WITH_DELETE_INTERNAL', 'UNSUPPRESS')")
return value

class Config:
Expand Down

0 comments on commit 89c197c

Please sign in to comment.