class WarningsValueListEntry(messages.Message): """A WarningsValueListEntry object. Enums: CodeValueValuesEnum: [Output Only] The warning type identifier for this warning. Messages: DataValueListEntry: A DataValueListEntry object. Fields: code: [Output Only] The warning type identifier for this warning. data: [Output Only] Metadata for this warning in key: value format. message: [Output Only] Optional human-readable details for this warning. """ class CodeValueValuesEnum(messages.Enum): """[Output Only] The warning type identifier for this warning. Values: DEPRECATED_RESOURCE_USED: <no description> DISK_SIZE_LARGER_THAN_IMAGE_SIZE: <no description> INJECTED_KERNELS_DEPRECATED: <no description> NEXT_HOP_ADDRESS_NOT_ASSIGNED: <no description> NEXT_HOP_CANNOT_IP_FORWARD: <no description> NEXT_HOP_INSTANCE_NOT_FOUND: <no description> NEXT_HOP_INSTANCE_NOT_ON_NETWORK: <no description> NEXT_HOP_NOT_RUNNING: <no description> NOT_CRITICAL_ERROR: <no description> NO_RESULTS_ON_PAGE: <no description> REQUIRED_TOS_AGREEMENT: <no description> RESOURCE_NOT_DELETED: <no description> SINGLE_INSTANCE_PROPERTY_TEMPLATE: <no description> UNREACHABLE: <no description> """ DEPRECATED_RESOURCE_USED = 0 DISK_SIZE_LARGER_THAN_IMAGE_SIZE = 1 INJECTED_KERNELS_DEPRECATED = 2 NEXT_HOP_ADDRESS_NOT_ASSIGNED = 3 NEXT_HOP_CANNOT_IP_FORWARD = 4 NEXT_HOP_INSTANCE_NOT_FOUND = 5 NEXT_HOP_INSTANCE_NOT_ON_NETWORK = 6 NEXT_HOP_NOT_RUNNING = 7 NOT_CRITICAL_ERROR = 8 NO_RESULTS_ON_PAGE = 9 REQUIRED_TOS_AGREEMENT = 10 RESOURCE_NOT_DELETED = 11 SINGLE_INSTANCE_PROPERTY_TEMPLATE = 12 UNREACHABLE = 13 class DataValueListEntry(messages.Message): """A DataValueListEntry object. Fields: key: [Output Only] A key for the warning data. value: [Output Only] A warning data value corresponding to the key. """ key = messages.StringField(1) value = messages.StringField(2) code = messages.EnumField('CodeValueValuesEnum', 1) data = messages.MessageField('DataValueListEntry', 2, repeated=True) message = messages.StringField(3)
class UserRankForm(messages.Message): """Return user rank info with their winning time and average winning attempts""" name = messages.StringField(1, required=True) win_time = messages.IntegerField(2, required=True) win_rate = messages.FloatField(3, required=True) total_guesses = messages.IntegerField(4, required=True)
class FileCountMessage(messages.Message): ext = messages.StringField(1) count = messages.IntegerField(2)
class HistoryForm(messages.Message): guess = messages.StringField(1, required=True) hitStatus = messages.BooleanField(2, required=True) winningStatus = messages.StringField(3, required=True)
class MakeMoveForm(messages.Message): """Used to make a move in an existing game""" guess = messages.StringField(1, required=True)
class ProfileMiniForm(messages.Message): """ProfileMiniForm -- update Profile form message""" displayName = messages.StringField(1) teeShirtSize = messages.EnumField('TeeShirtSize', 2)
class WishlistForm(messages.Message): """Wishlist message""" sessionKeys = messages.StringField(2, repeated=True)
class TagMessage(messages.Message): name = messages.StringField(1) cnt = messages.IntegerField(2)
class TagsResponseMessage(messages.Message): code = messages.IntegerField(1) text = messages.StringField(2) tags = messages.MessageField(TagMessage, 3, repeated=True)
class ApiErrorMessage(messages.Message): code = messages.IntegerField(1) text = messages.StringField(2)
class IsInBaseResponseMessage(messages.Message): code = messages.IntegerField(1) text = messages.StringField(2) pages_count = messages.IntegerField(3)
class UrlRequestMessage(messages.Message): url = messages.StringField(1, required=True)
'GTEQ': '>=', 'LT': '<', 'LTEQ': '<=', 'NE': '!=' } FIELDS = { 'CITY': 'city', 'TOPIC': 'topics', 'MONTH': 'month', 'MAX_ATTENDEES': 'maxAttendees', } CONF_GET_REQUEST = endpoints.ResourceContainer( message_types.VoidMessage, websafeConferenceKey=messages.StringField(1), ) CONF_POST_REQUEST = endpoints.ResourceContainer( ConferenceForm, websafeConferenceKey=messages.StringField(1), ) # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @endpoints.api(name='conference', version='v1', allowed_client_ids=[WEB_CLIENT_ID, API_EXPLORER_CLIENT_ID], scopes=[EMAIL_SCOPE]) class ConferenceApi(remote.Service): """Conference API v0.1"""
class MyMessage(messages.Message): number = messages.IntegerField(1) names = messages.StringField(2, repeated=True)
class DefaultResponse(messages.Message): content = messages.StringField(1)
class HouseResponseMessage(messages.Message): code = messages.IntegerField(1) text = messages.StringField(2) house = messages.MessageField(HouseMessage, 3)
class ConferenceQueryForm(messages.Message): """ConferenceQueryForm -- Conference query inbound form message""" field = messages.StringField(1) operator = messages.StringField(2) value = messages.StringField(3)
class HousesResponseMessage(messages.Message): code = messages.IntegerField(1) text = messages.StringField(2) houses = messages.MessageField(HouseMessage, 3, repeated=True)
class ProfileForm(messages.Message): """ProfileForm -- Profile outbound form message""" displayName = messages.StringField(1) mainEmail = messages.StringField(2) teeShirtSize = messages.EnumField('TeeShirtSize', 3) conferenceKeysToAttend = messages.StringField(4, repeated=True)
class Device(messages.Message): """Device ProtoRPC message. Attributes: serial_number: str, The serial number of the Chrome device. asset_tag: str, The asset tag of the Chrome device. identifier: str, The computed identifier for a device. Serial number if asset tag is not provided. enrolled: bool, Indicates the enrollment status of the device. device_model: int, Identifies the model name of the device. due_date: datetime, The date that device is due for return. last_know_healthy: datetime, The date to indicate the last known healthy status. shelf: shelf_messages.Shelf, The message for a shelf. assigned_user: str, The email of the user who is assigned to the device. assignment_date: datetime, The date the device was assigned to a user. current_ou: str, The current organizational unit the device belongs to. ou_change_date: datetime, The date the organizational unit was changed. locked: bool, Indicates whether or not the device is locked. lost: bool, Indicates whether or not the device is lost. mark_pending_return_date: datetime, The date a user marked device returned. chrome_device_id: str, A unique device ID. last_heartbeat: datetime, The date of the last time the device checked in. damaged: bool, Indicates the if the device is damaged. damaged_reason: str, A string denoting the reason for being reported as damaged. last_reminder: Reminder, Level, time, and count of the last reminder the device had. next_reminder: Reminder, Level, time, and count of the next reminder. page_token: str, A page token to query next page results. page_size: int, The number of results to query for and display. max_extend_date: datetime, Indicates maximum extend date a device can have. guest_enabled: bool, Indicates if guest mode has been already enabled. guest_permitted: bool, Indicates if guest mode has been allowed. given_name: str, The given name for the user. query: shared_message.SearchRequest, a message containing query options to conduct a search on an index. overdue: bool, Indicates that the due date has passed. tags: List[tag_model.TagData], a list of TagData objects associated with the device. onboarded: bool, Indicates that the device has been fully onboarded. """ serial_number = messages.StringField(1) asset_tag = messages.StringField(2) identifier = messages.StringField(3) urlkey = messages.StringField(4) enrolled = messages.BooleanField(5, default=True) device_model = messages.StringField(6) due_date = message_types.DateTimeField(7) last_known_healthy = message_types.DateTimeField(8) shelf = messages.MessageField(shelf_messages.Shelf, 9) assigned_user = messages.StringField(10) assignment_date = message_types.DateTimeField(11) current_ou = messages.StringField(12) ou_changed_date = message_types.DateTimeField(13) locked = messages.BooleanField(14) lost = messages.BooleanField(15) mark_pending_return_date = message_types.DateTimeField(16) chrome_device_id = messages.StringField(17) last_heartbeat = message_types.DateTimeField(18) damaged = messages.BooleanField(19) damaged_reason = messages.StringField(20) last_reminder = messages.MessageField(Reminder, 21) next_reminder = messages.MessageField(Reminder, 22) page_token = messages.StringField(23) page_size = messages.IntegerField(24, default=25) max_extend_date = message_types.DateTimeField(25) guest_enabled = messages.BooleanField(26) guest_permitted = messages.BooleanField(27) given_name = messages.StringField(28) query = messages.MessageField(shared_messages.SearchRequest, 29) overdue = messages.BooleanField(30) tags = messages.MessageField(tag_messages.TagData, 31, repeated=True) onboarded = messages.BooleanField(32)
class Greeting(messages.Message): """Greeting that stores a message.""" message = messages.StringField(1)
class RegistrationRequest(messages.Message): clientID = messages.StringField(1)
class NewGameForm(messages.Message): """Used to create a new game""" user_name = messages.StringField(1, required=True) word = messages.StringField(2, required=True)
class AddMessageMockRequest (messages.Message): fromApp = messages.StringField(1) messageType = messages.StringField(2) class SendMessageRequest (messages.Message): topic = messages.StringField(1) numberOfMessage = messages.IntegerField(2) messageType = messages.StringField(3) class DefaultResponse(messages.Message): content = messages.StringField(1) ADD_MSG_RESOURCE = endpoints.ResourceContainer( AddMessageMockRequest, jsonMessage = messages.StringField(2)) GET_MSG_RESOURCE = endpoints.ResourceContainer( messageType = messages.StringField(1)) SEND_MSG_RESOURCE = endpoints.ResourceContainer(SendMessageRequest) # [END messages] # [START echo_api] @endpoints.api(name='loadpubsub', version='v1') class LoadPubSubApi(remote.Service): @endpoints.method( # This method takes a ResourceContainer defined above.
class ScoreForm(messages.Message): """ScoreForm for outbound Score information""" user_name = messages.StringField(1, required=True) date = messages.StringField(2, required=True) won = messages.BooleanField(3, required=True) guesses = messages.IntegerField(4, required=True)
class AddMessageMockRequest (messages.Message): fromApp = messages.StringField(1) messageType = messages.StringField(2)
class StringMessage(messages.Message): """StringMessage-- outbound (single) string message""" message = messages.StringField(1, required=True)
class SendMessageRequest (messages.Message): topic = messages.StringField(1) numberOfMessage = messages.IntegerField(2) messageType = messages.StringField(3)
class MessageNone(messages.Message): inti = messages.StringField(1)
class Operation(messages.Message): """An operation resource, used to manage asynchronous API requests. Enums: StatusValueValuesEnum: [Output Only] Status of the operation. Can be one of the following: PENDING, RUNNING, or DONE. Messages: ErrorValue: [Output Only] If errors are generated during processing of the operation, this field will be populated. WarningsValueListEntry: A WarningsValueListEntry object. Fields: clientOperationId: [Output Only] An optional identifier specified by the client when the mutation was initiated. Must be unique for all operation resources in the project. creationTimestamp: [Output Only] Creation timestamp in RFC3339 text format. endTime: [Output Only] The time that this operation was completed. This is in RFC3339 text format. error: [Output Only] If errors are generated during processing of the operation, this field will be populated. httpErrorMessage: [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND. httpErrorStatusCode: [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as 404. id: [Output Only] Unique identifier for the resource; defined by the server. insertTime: [Output Only] The time that this operation was requested. This is in RFC3339 text format. kind: [Output Only] Type of the resource. Always compute#Operation for Operation resources. name: [Output Only] Name of the resource. operationType: [Output Only] Type of the operation, such as insert, update, and delete. progress: [Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess at when the operation will be complete. This number should monotonically increase as the operation progresses. region: [Output Only] URL of the region where the operation resides. Only applicable for regional resources. selfLink: [Output Only] Server defined URL for the resource. startTime: [Output Only] The time that this operation was started by the server. This is in RFC3339 text format. status: [Output Only] Status of the operation. Can be one of the following: PENDING, RUNNING, or DONE. statusMessage: [Output Only] An optional textual description of the current status of the operation. targetId: [Output Only] Unique target ID which identifies a particular incarnation of the target. targetLink: [Output Only] URL of the resource the operation is mutating. user: [Output Only] User who requested the operation, for example: [email protected]. warnings: [Output Only] If warning messages are generated during processing of the operation, this field will be populated. zone: [Output Only] URL of the zone where the operation resides. """ class StatusValueValuesEnum(messages.Enum): """[Output Only] Status of the operation. Can be one of the following: PENDING, RUNNING, or DONE. Values: DONE: <no description> PENDING: <no description> RUNNING: <no description> """ DONE = 0 PENDING = 1 RUNNING = 2 class ErrorValue(messages.Message): """[Output Only] If errors are generated during processing of the operation, this field will be populated. Messages: ErrorsValueListEntry: A ErrorsValueListEntry object. Fields: errors: [Output Only] The array of errors encountered while processing this operation. """ class ErrorsValueListEntry(messages.Message): """A ErrorsValueListEntry object. Fields: code: [Output Only] The error type identifier for this error. location: [Output Only] Indicates the field in the request which caused the error. This property is optional. message: [Output Only] An optional, human-readable error message. """ code = messages.StringField(1) location = messages.StringField(2) message = messages.StringField(3) errors = messages.MessageField('ErrorsValueListEntry', 1, repeated=True) class WarningsValueListEntry(messages.Message): """A WarningsValueListEntry object. Enums: CodeValueValuesEnum: [Output Only] The warning type identifier for this warning. Messages: DataValueListEntry: A DataValueListEntry object. Fields: code: [Output Only] The warning type identifier for this warning. data: [Output Only] Metadata for this warning in key: value format. message: [Output Only] Optional human-readable details for this warning. """ class CodeValueValuesEnum(messages.Enum): """[Output Only] The warning type identifier for this warning. Values: DEPRECATED_RESOURCE_USED: <no description> DISK_SIZE_LARGER_THAN_IMAGE_SIZE: <no description> INJECTED_KERNELS_DEPRECATED: <no description> NEXT_HOP_ADDRESS_NOT_ASSIGNED: <no description> NEXT_HOP_CANNOT_IP_FORWARD: <no description> NEXT_HOP_INSTANCE_NOT_FOUND: <no description> NEXT_HOP_INSTANCE_NOT_ON_NETWORK: <no description> NEXT_HOP_NOT_RUNNING: <no description> NOT_CRITICAL_ERROR: <no description> NO_RESULTS_ON_PAGE: <no description> REQUIRED_TOS_AGREEMENT: <no description> RESOURCE_NOT_DELETED: <no description> SINGLE_INSTANCE_PROPERTY_TEMPLATE: <no description> UNREACHABLE: <no description> """ DEPRECATED_RESOURCE_USED = 0 DISK_SIZE_LARGER_THAN_IMAGE_SIZE = 1 INJECTED_KERNELS_DEPRECATED = 2 NEXT_HOP_ADDRESS_NOT_ASSIGNED = 3 NEXT_HOP_CANNOT_IP_FORWARD = 4 NEXT_HOP_INSTANCE_NOT_FOUND = 5 NEXT_HOP_INSTANCE_NOT_ON_NETWORK = 6 NEXT_HOP_NOT_RUNNING = 7 NOT_CRITICAL_ERROR = 8 NO_RESULTS_ON_PAGE = 9 REQUIRED_TOS_AGREEMENT = 10 RESOURCE_NOT_DELETED = 11 SINGLE_INSTANCE_PROPERTY_TEMPLATE = 12 UNREACHABLE = 13 class DataValueListEntry(messages.Message): """A DataValueListEntry object. Fields: key: [Output Only] A key for the warning data. value: [Output Only] A warning data value corresponding to the key. """ key = messages.StringField(1) value = messages.StringField(2) code = messages.EnumField('CodeValueValuesEnum', 1) data = messages.MessageField('DataValueListEntry', 2, repeated=True) message = messages.StringField(3) clientOperationId = messages.StringField(1) creationTimestamp = messages.StringField(2) endTime = messages.StringField(3) error = messages.MessageField('ErrorValue', 4) httpErrorMessage = messages.StringField(5) httpErrorStatusCode = messages.IntegerField(6, variant=messages.Variant.INT32) id = messages.IntegerField(7, variant=messages.Variant.UINT64) insertTime = messages.StringField(8) kind = messages.StringField(9, default=u'computeaccounts#operation') name = messages.StringField(10) operationType = messages.StringField(11) progress = messages.IntegerField(12, variant=messages.Variant.INT32) region = messages.StringField(13) selfLink = messages.StringField(14) startTime = messages.StringField(15) status = messages.EnumField('StatusValueValuesEnum', 16) statusMessage = messages.StringField(17) targetId = messages.IntegerField(18, variant=messages.Variant.UINT64) targetLink = messages.StringField(19) user = messages.StringField(20) warnings = messages.MessageField('WarningsValueListEntry', 21, repeated=True) zone = messages.StringField(22)