openapi: 3.2.0 info: title: CRM Field Schema Customization Service API version: 0.157.0 servers: - description: Production url: https://prod.apigateway.co/grpc tags: - name: CRMFieldSchemaCustomizationService paths: /v1/crm/field-schema-customization/create: post: operationId: CRMFieldSchemaCustomizationService_CreateFieldSchemaCustomization requestBody: content: application/json: schema: $ref: '#/components/schemas/v1CreateFieldSchemaCustomizationRequest' description: Request to create a field schema customization, which restricts the allowed values for a specific field on a CRM object type within a namespace. required: true responses: '200': content: application/json: schema: type: object description: A successful response. default: content: application/json: schema: $ref: '#/components/schemas/rpcStatus' description: An unexpected error response. security: - OAuth2: - crm - crm.schema summary: Create Field Schema Customization tags: - CRMFieldSchemaCustomizationService /v1/crm/field-schema-customization/delete: post: operationId: CRMFieldSchemaCustomizationService_DeleteFieldSchemaCustomization requestBody: content: application/json: schema: $ref: '#/components/schemas/v1DeleteFieldSchemaCustomizationRequest' description: Request to delete a field schema customization for a specific field on a CRM object type within a namespace. required: true responses: '200': content: application/json: schema: type: object description: A successful response. default: content: application/json: schema: $ref: '#/components/schemas/rpcStatus' description: An unexpected error response. security: - OAuth2: - crm - crm.schema summary: Delete Field Schema Customization tags: - CRMFieldSchemaCustomizationService /v1/crm/field-schema-customization/get-multi: post: operationId: CRMFieldSchemaCustomizationService_GetMultiFieldSchemaCustomization requestBody: content: application/json: schema: $ref: '#/components/schemas/v1GetMultiFieldSchemaCustomizationRequest' description: Request to retrieve field schema customizations for the specified fields on a CRM object type within a namespace. required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/v1GetMultiFieldSchemaCustomizationResponse' description: A successful response. default: content: application/json: schema: $ref: '#/components/schemas/rpcStatus' description: An unexpected error response. security: - OAuth2: - crm - crm.schema:read summary: Get Multi Field Schema Customization tags: - CRMFieldSchemaCustomizationService /v1/crm/field-schema-customization/list: post: operationId: CRMFieldSchemaCustomizationService_ListFieldSchemaCustomization requestBody: content: application/json: schema: $ref: '#/components/schemas/v1ListFieldSchemaCustomizationRequest' description: Request to list field schema customizations within a namespace, optionally filtered by CRM object type. required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/v1ListFieldSchemaCustomizationResponse' description: A successful response. default: content: application/json: schema: $ref: '#/components/schemas/rpcStatus' description: An unexpected error response. security: - OAuth2: - crm - crm.schema:read summary: List Field Schema Customization tags: - CRMFieldSchemaCustomizationService /v1/crm/field-schema-customization/update: post: operationId: CRMFieldSchemaCustomizationService_UpdateFieldSchemaCustomization requestBody: content: application/json: schema: $ref: '#/components/schemas/v1UpdateFieldSchemaCustomizationRequest' description: Request to update an existing field schema customization on a CRM object type within a namespace. required: true responses: '200': content: application/json: schema: type: object description: A successful response. default: content: application/json: schema: $ref: '#/components/schemas/rpcStatus' description: An unexpected error response. security: - OAuth2: - crm - crm.schema summary: Update Field Schema Customization tags: - CRMFieldSchemaCustomizationService components: schemas: v1PhoneFields: properties: e164Compliant: title: This flags signals if the number is compliant with the E164 format type: boolean extension: title: An extension number type: string isoCountryCode: title: ISO country code is the 2 or 3 letter code for the country, example 'CA' for Canada type: string nationalNumber: title: The main phone number without the country code type: string type: object vendastatypesPagedRequestOptions: properties: cursor: description: Optional. An opaque token from a previous response's next_cursor to retrieve the next page of results. Omit or leave empty for the first page. type: string pageSize: description: Optional. The maximum number of items to return per page. format: int64 type: string type: object v1FieldValue: description: 'FieldValue represents one of the fields of a crm object (Contact, Company, etc...) On Create/Update we need the field_id or external_id filled, with the field_id taking precedence over external_id. When retrieving both field_id and external_id will be returned.' properties: booleanValue: title: A boolean value type: boolean currencyValue: $ref: '#/components/schemas/v1Currency' dateValue: format: date-time title: A timestamp value type: string externalId: title: An external identifier for the field, not required type: string fieldId: title: The identifier of the field type: string floatValue: format: float title: A float number value type: number geopointValue: $ref: '#/components/schemas/v1Geopoint' integerValue: format: int64 title: An Integer value type: string nullValue: title: Empty value type: string phoneFieldValues: $ref: '#/components/schemas/v1PhoneFields' stringValue: title: A string value type: string stringValues: $ref: '#/components/schemas/v1StringList' type: object v1Geopoint: properties: lat: format: double title: Latitude type: number lon: format: double title: Longitude type: number title: Values for geo-location type: object v1ListFieldSchemaCustomizationResponse: description: Response containing a page of field schema customizations matching the request criteria. properties: fieldSchemaCustomizations: description: The field schema customizations matching the request criteria for this page. items: $ref: '#/components/schemas/v1FieldSchemaCustomization' type: array pagingMetadata: $ref: '#/components/schemas/vendastatypesPagedResponseMetadata' title: List Field Schema Customization Response type: object v1DeleteFieldSchemaCustomizationRequest: description: Request to delete a field schema customization for a specific field on a CRM object type within a namespace. properties: crmObjectType: description: Required. The CRM object type the field belongs to (e.g. "contact", "company", "opportunity"). type: string fieldId: description: Required. The field ID whose customization should be deleted. type: string namespace: description: Required. The namespace (partner ID or account group ID) the customization applies to. type: string required: - namespace - crmObjectType - fieldId title: Delete Field Schema Customization Request type: object rpcStatus: properties: code: format: int32 type: integer details: items: $ref: '#/components/schemas/protobufAny' type: array message: type: string type: object v1GetMultiFieldSchemaCustomizationRequest: description: Request to retrieve field schema customizations for the specified fields on a CRM object type within a namespace. properties: crmObjectType: description: Required. The CRM object type the fields belong to (e.g. "contact", "company", "opportunity"). type: string fieldId: description: Required. The field IDs whose customizations should be retrieved. items: type: string type: array namespace: description: Required. The namespace (partner ID or account group ID) to look up customizations for. type: string required: - namespace - crmObjectType - fieldId title: Get Multi Field Schema Customization Request type: object v1UpdateFieldSchemaCustomizationRequest: description: Request to update an existing field schema customization on a CRM object type within a namespace. properties: crmObjectType: description: Required. The CRM object type the field belongs to (e.g. "contact", "company", "opportunity"). type: string fieldMask: $ref: '#/components/schemas/vendastatypesFieldMask' fieldSchemaCustomization: $ref: '#/components/schemas/v1FieldSchemaCustomization' namespace: description: Required. The namespace (partner ID or account group ID) the customization applies to. type: string required: - namespace - crmObjectType - fieldSchemaCustomization title: Update Field Schema Customization Request type: object v1GetMultiFieldSchemaCustomizationResponse: description: Response containing the requested field schema customizations. properties: fieldSchemaCustomizations: description: The field schema customizations that were found. Fields without a customization are omitted. items: $ref: '#/components/schemas/v1FieldSchemaCustomization' type: array title: Get Multi Field Schema Customization Response type: object v1CreateFieldSchemaCustomizationRequest: description: Request to create a field schema customization, which restricts the allowed values for a specific field on a CRM object type within a namespace. properties: crmObjectType: description: Required. The CRM object type the field belongs to (e.g. "contact", "company", "opportunity"). type: string fieldSchemaCustomization: $ref: '#/components/schemas/v1FieldSchemaCustomization' namespace: description: Required. The namespace (partner ID or account group ID) the customization applies to. type: string required: - namespace - crmObjectType - fieldSchemaCustomization title: Create Field Schema Customization Request type: object vendastatypesFieldMask: description: "paths: \"f.a\"\n paths: \"f.b.d\"\n\nHere `f` represents a field in some root message, `a` and `b`\nfields in the message found in `f`, and `d` a field found in the\nmessage in `f.b`.\n\nField masks are used to specify a subset of fields that should be\nreturned by a get operation or modified by an update operation.\nField masks also have a custom JSON encoding (see below).\n\n# Field Masks in Projections\n\nWhen used in the context of a projection, a response message or\nsub-message is filtered by the API to only contain those fields as\nspecified in the mask. For example, if the mask in the previous\nexample is applied to a response message as follows:\n\n f {\n a : 22\n b {\n d : 1\n x : 2\n }\n y : 13\n }\n z: 8\n\nThe result will not contain specific values for fields x,y and z\n(their value will be set to the default, and omitted in proto text\noutput):\n\n\n f {\n a : 22\n b {\n d : 1\n }\n }\n\nA repeated field is not allowed except at the last position of a\npaths string.\n\nIf a FieldMask object is not present in a get operation, the\noperation applies to all fields (as if a FieldMask of all fields\nhad been specified).\n\nNote that a field mask does not necessarily apply to the\ntop-level response message. In case of a REST get operation, the\nfield mask applies directly to the response, but in case of a REST\nlist operation, the mask instead applies to each individual message\nin the returned resource list. In case of a REST custom method,\nother definitions may be used. Where the mask applies will be\nclearly documented together with its declaration in the API. In\nany case, the effect on the returned resource/resources is required\nbehavior for APIs.\n\n# Field Masks in Update Operations\n\nA field mask in update operations specifies which fields of the\ntargeted resource are going to be updated. The API is required\nto only change the values of the fields as specified in the mask\nand leave the others untouched. If a resource is passed in to\ndescribe the updated values, the API ignores the values of all\nfields not covered by the mask.\n\nIf a repeated field is specified for an update operation, the existing\nrepeated values in the target resource will be overwritten by the new values.\nNote that a repeated field is only allowed in the last position of a `paths`\nstring.\n\nIf a sub-message is specified in the last position of the field mask for an\nupdate operation, then the existing sub-message in the target resource is\noverwritten. Given the target message:\n\n f {\n b {\n d : 1\n x : 2\n }\n c : 1\n }\n\nAnd an update message:\n\n f {\n b {\n d : 10\n }\n }\n\nthen if the field mask is:\n\n paths: \"f.b\"\n\nthen the result will be:\n\n f {\n b {\n d : 10\n }\n c : 1\n }\n\nHowever, if the update mask was:\n\n paths: \"f.b.d\"\n\nthen the result would be:\n\n f {\n b {\n d : 10\n x : 2\n }\n c : 1\n }\n\nIn order to reset a field's value to the default, the field must\nbe in the mask and set to the default value in the provided resource.\nHence, in order to reset all fields of a resource, provide a default\ninstance of the resource and set all fields in the mask, or do\nnot provide a mask as described below.\n\nIf a field mask is not present on update, the operation applies to\nall fields (as if a field mask of all fields has been specified).\nNote that in the presence of schema evolution, this may mean that\nfields the client does not know and has therefore not filled into\nthe request will be reset to their default. If this is unwanted\nbehavior, a specific service may require a client to always specify\na field mask, producing an error if not.\n\nAs with get operations, the location of the resource which\ndescribes the updated values in the request message depends on the\noperation kind. In any case, the effect of the field mask is\nrequired to be honored by the API.\n\n## Considerations for HTTP REST\n\nThe HTTP kind of an update operation which uses a field mask must\nbe set to PATCH instead of PUT in order to satisfy HTTP semantics\n(PUT must only be used for full updates).\n\n# JSON Encoding of Field Masks\n\nIn JSON, a field mask is encoded as a single string where paths are\nseparated by a comma. Fields name in each path are converted\nto/from lower-camel naming conventions.\n\nAs an example, consider the following message declarations:\n\n message Profile {\n User user = 1;\n Photo photo = 2;\n }\n message User {\n string display_name = 1;\n string address = 2;\n }\n\nIn proto a field mask for `Profile` may look as such:\n\n mask {\n paths: \"user.display_name\"\n paths: \"photo\"\n }\n\nIn JSON, the same mask is represented as below:\n\n {\n mask: \"user.displayName,photo\"\n }\n\n# Field Masks and Oneof Fields\n\nField masks treat fields in oneofs just as regular fields. Consider the\nfollowing message:\n\n message SampleMessage {\n oneof test_oneof {\n string name = 4;\n SubMessage sub_message = 9;\n }\n }\n\nThe field mask can be:\n\n mask {\n paths: \"name\"\n }\n\nOr:\n\n mask {\n paths: \"sub_message\"\n }\n\nNote that oneof type names (\"test_oneof\" in this case) cannot be used in\npaths." properties: paths: description: The set of field mask paths. items: type: string type: array title: '`FieldMask` represents a set of symbolic field paths, for example:' type: object v1Currency: properties: currencyCode: title: ISO 4217 currency code type: string value: format: double title: Amount type: number type: object v1FieldSchemaCustomization: properties: created: format: date-time type: string deleted: format: date-time type: string fieldId: type: string namespace: description: For create or update requests, this should be omitted. type: string restrictedFieldValues: items: $ref: '#/components/schemas/v1FieldValue' type: array updated: format: date-time type: string type: object v1StringList: properties: values: items: type: string title: A list of values of type string type: array type: object v1ListFieldSchemaCustomizationRequest: description: Request to list field schema customizations within a namespace, optionally filtered by CRM object type. properties: crmObjectType: description: Optional. The CRM object type to filter by (e.g. "contact", "company", "opportunity"). Use "*" to return customizations for all object types. type: string namespace: description: Required. The namespace (partner ID or account group ID) to list customizations for. type: string pagingOptions: $ref: '#/components/schemas/vendastatypesPagedRequestOptions' required: - namespace title: List Field Schema Customization Request type: object vendastatypesPagedResponseMetadata: properties: hasMore: title: Whether or not more results exist type: boolean nextCursor: title: A cursor that can be provided to retrieve the next page of results type: string totalResults: format: int64 title: The total number of results. This is not supported on all paged apis and will be 0 if it is not supported type: string type: object protobufAny: additionalProperties: {} properties: '@type': type: string type: object securitySchemes: OAuth2: flows: authorizationCode: authorizationUrl: https://sso-api-prod.apigateway.co/oauth2/auth scopes: crm: Allows the application to manage all data in your CRM crm.association: Allows the application to manage associations in your CRM crm.association:read: Allows the application view-only access to associations in your CRM crm.company: Allows the application to manage your CRM companies crm.company:read: Allows the application view-only access to CRM companies crm.contact: Allows the application to manage your CRM contacts crm.contact:read: Allows the application view-only access to CRM contacts crm.custom-object: Allows the application to manage your CRM custom objects crm.custom-object:read: Allows the application view-only access to CRM custom objects crm.opportunity: Allows the application to manage your CRM opportunities crm.opportunity:read: Allows the application view-only access to CRM opportunities crm.schema: Allows the application to manage your CRM object schemas crm.schema:read: Allows the application view-only access to CRM object schemas tokenUrl: https://sso-api-prod.apigateway.co/oauth2/token type: oauth2