Create an opportunity contact
post
/crmRestApi/resources/11.13.18.05/opportunities/{OptyNumber}/child/OpportunityContact
Request
Path Parameters
-
OptyNumber(required): string
The unique alternate identifier for the opportunity.
Header Parameters
-
Metadata-Context:
If the REST API supports runtime customizations, the shape of the service may change during runtime. The REST client may isolate itself from these changes or choose to interact with the latest version of the API by specifying this header. For example: Metadata-Context:sandbox="TrackEmployeeFeature".
-
REST-Framework-Version:
The protocol version between a REST client and service. If the client does not specify this header in the request the server will pick a default version for the API.
-
Upsert-Mode:
Contains one of the following values: true or false. If true, the server performs an Upsert operation instead of a Create operation. During an Upsert operation, the server attempts to find an existing resource that matches the payload. If a match is found, the server updates the existing resource instead of creating a new one. If not found or false (default), the server performs a Create operation. Note that the Upsert operation isn't supported for date-effective REST resources.
Supported Media Types
- application/json
Root Schema : schema
Type:
Show Source
object
-
AffinityLvlCd: string
Title:
Affinity Level
Maximum Length:30
The code indicating the affinity of the opportunity contact to the deploying organization. A list of accepted values is defined in the lookup HZ_SLS_CNTCT_AFFINITY_CODE. Review and update the value for this attribute using the Setup and Maintenance work area, Manage Contact Lookups task. -
Comments: string
Title:
Comments
Maximum Length:255
The textual comments about the contact on the current opportunity. -
ConflictId: integer
(int64)
Title:
Conflict ID
Default Value:0
The value used to guarantee the uniqueness of the row when duplicates are created in different databases in case of a disconnected mobile such as mobile databases, or the server. -
ContactedFlg: string
Title:
Contacted
Maximum Length:1
Default Value:N
Indicates if the contact for this opportunity has been contacted. If the value is True, then the contact was contacted. The default value is False. -
ContactPointId: integer
The unique identifier of the contact point for an opportunity contact.
-
InfluenceLvlCd: string
Title:
Influence Level
Maximum Length:30
The code indicating the influence the opportunity contact has on the deploying organization. A list of accepted values is defined in the lookup HZ_SLS_CNTCT_INFLUENCE_LVL_CD. Review and update the value for this attribute using the Setup and Maintenance work area, Manage Contact Lookups task. -
LastUpdateLogin: string
Maximum Length:
32
The session login associated to the user who last updated the record. -
OptyConId: integer
(int64)
Title:
Contact ID
The unique identifier of the contact associated with the opportunity. -
OptyId: integer
(int64)
Title:
Opportunity
The unique identifier of the opportunity. -
OptyNumber: string
Title:
Opportunity Number
Maximum Length:30
The unique alternate identifier for the opportunity. -
PERPartyId: integer
(int64)
Title:
Opportunity Contact
The party identifier of the opportunity contact. -
PrimaryFlg: string
Title:
Primary
Indicates if the contact is the primary contact for the opportunity. If the value is True, then the contact is the primary contact of the opportunity. The default value is False. -
RelationshipId: integer
(int64)
The identifier of the relationship for the opportunity contact.
-
RoleCd: string
Title:
Function
Maximum Length:30
The code identifying the roles played by a contact in the opportunity. A list of accepted values is defined in the lookup HZ_SLS_CNTCT_BUY_ROLE_CODE. Review and update the values for this attribute using the Setup and Maintenance work area, Manage Contact Lookups task.
Response
Supported Media Types
- application/json
Default Response
The following table describes the default response for this task.
Headers
-
Metadata-Context:
If the REST API supports runtime customizations, the shape of the service may change during runtime. The REST client may isolate itself from these changes or choose to interact with the latest version of the API by specifying this header. For example: Metadata-Context:sandbox="TrackEmployeeFeature".
-
REST-Framework-Version:
The protocol version between a REST client and service. If the client does not specify this header in the request the server will pick a default version for the API.
Root Schema : opportunities-OpportunityContact-item-response
Type:
Show Source
object
-
AffinityLvlCd: string
Title:
Affinity Level
Maximum Length:30
The code indicating the affinity of the opportunity contact to the deploying organization. A list of accepted values is defined in the lookup HZ_SLS_CNTCT_AFFINITY_CODE. Review and update the value for this attribute using the Setup and Maintenance work area, Manage Contact Lookups task. -
Comments: string
Title:
Comments
Maximum Length:255
The textual comments about the contact on the current opportunity. -
ConflictId: integer
(int64)
Title:
Conflict ID
Default Value:0
The value used to guarantee the uniqueness of the row when duplicates are created in different databases in case of a disconnected mobile such as mobile databases, or the server. -
ContactedFlg: string
Title:
Contacted
Maximum Length:1
Default Value:N
Indicates if the contact for this opportunity has been contacted. If the value is True, then the contact was contacted. The default value is False. -
ContactPartyNumber: string
Title:
Registry ID
Read Only:true
Maximum Length:30
The alternate key identifier of the opportunity contact party. -
ContactPointId: integer
The unique identifier of the contact point for an opportunity contact.
-
CreatedBy: string
Read Only:
true
Maximum Length:64
The user who created the opportunity contact record. -
CreationDate: string
(date-time)
Read Only:
true
The date and time when the contact record was created. -
DoNotContactFlag: boolean
Title:
Do Not Contact
Read Only:true
Maximum Length:1
Indicates if the user can contact the person or not by phone, e-mail, or mail. If the value is True, then the user must not contact the person. The default is False. -
EmailAddress: string
Title:
Email
Read Only:true
The e-mail address of the contact. -
EmailPreference: string
Title:
Email Preference
Read Only:true
Maximum Length:255
Indicates if the opportunity contact has an email preference of do not email, ok to email, or no value. -
FormattedAddress: string
Title:
Address
Read Only:true
Maximum Length:255
The formatted address of the contact. -
FormattedPhoneNumber: string
Title:
Phone
Read Only:true
The formatted phone number of the contact. -
InfluenceLvlCd: string
Title:
Influence Level
Maximum Length:30
The code indicating the influence the opportunity contact has on the deploying organization. A list of accepted values is defined in the lookup HZ_SLS_CNTCT_INFLUENCE_LVL_CD. Review and update the value for this attribute using the Setup and Maintenance work area, Manage Contact Lookups task. -
JobTitle: string
Title:
Title
Read Only:true
Maximum Length:100
The free form text for job title of the opportunity contact. -
LastUpdateDate: string
(date-time)
Read Only:
true
The date when the record was last updated. -
LastUpdatedBy: string
Read Only:
true
Maximum Length:64
The user who last updated the record. -
LastUpdateLogin: string
Maximum Length:
32
The session login associated to the user who last updated the record. -
links: array
Links
Title:
Links
The link relations associated with the resource instance. -
OptyConId: integer
(int64)
Title:
Contact ID
The unique identifier of the contact associated with the opportunity. -
OptyId: integer
(int64)
Title:
Opportunity
The unique identifier of the opportunity. -
OptyNumber: string
Title:
Opportunity Number
Maximum Length:30
The unique alternate identifier for the opportunity. -
OrganizationPartyId: integer
(int64)
Read Only:
true
The unique identifier of the contact's organization. -
OrganizationPartyName: string
Title:
Organization
Read Only:true
Maximum Length:360
The name of the contact's organization. -
OrgContactId: integer
(int64)
Read Only:
true
The unique identifier of the organization contact for the opportunity. -
PartyName: string
Title:
Opportunity Contact Name
Read Only:true
Maximum Length:360
The name of the contact for the opportunity. -
PartyUniqueName: string
Title:
Related Account
Read Only:true
Maximum Length:900
The unique contact name displayed on party related screens. The default value for Contacts is the concatenation of attributes ContactName and UniqueNameSuffix. The default value for Organizations is the concatenation of the unique name alias and UniqueNameSuffix. -
PERPartyId: integer
(int64)
Title:
Opportunity Contact
The party identifier of the opportunity contact. -
PersonCentricJobTitle: string
Title:
Job Title
Read Only:true
Maximum Length:100
The job title of the contact person. -
PhonePreference: string
Title:
Phone Preference
Read Only:true
Maximum Length:255
Indicates if the opportunity contact has a phone preference of do not call, ok to call, or no value. -
PreferredContactMethod: string
Title:
Preferred Contact Method
Read Only:true
Maximum Length:30
The preferred method to contact the person. A list of accepted values is defined in the lookup HZ_PREFERRED_CONTACT_METHOD. Review and update the value for this attribute using the Setup and Maintenance work area, Manage Contact Point Lookups task. -
PrimaryFlg: string
Title:
Primary
Indicates if the contact is the primary contact for the opportunity. If the value is True, then the contact is the primary contact of the opportunity. The default value is False. -
RelationshipCode: string
Title:
Relationship Code
Read Only:true
Maximum Length:30
The code indicating whether it's a forward or a backward relationship. A list of accepted relationship values is defined in the lookup PARTY_RELATIONS_TYPE. Review and update the value for this attribute using the Setup and Maintenance work area, Manage Relationship Lookups. -
RelationshipId: integer
(int64)
The identifier of the relationship for the opportunity contact.
-
RoleCd: string
Title:
Function
Maximum Length:30
The code identifying the roles played by a contact in the opportunity. A list of accepted values is defined in the lookup HZ_SLS_CNTCT_BUY_ROLE_CODE. Review and update the values for this attribute using the Setup and Maintenance work area, Manage Contact Lookups task. -
SalesAffinityCode: string
Title:
Affinity
Read Only:true
Maximum Length:30
The code indicating the affinity of the opportunity contact to the deploying organization. A list of accepted values is defined in the lookup HZ_SLS_CNTCT_AFFINITY_CODE. Review and update the value for this attribute using the Setup and Maintenance work area, Manage Contact Lookups task. -
SalesBuyingRoleCode: string
Title:
Buying Role
Read Only:true
Maximum Length:30
The code identifying the roles played by a contact in the buying process. A list of accepted values is defined in the lookup HZ_SLS_CNTCT_BUY_ROLE_CODE. Review and update the values for this attribute using the Setup and Maintenance work area, Manage Contact Lookups task. -
SalesInfluenceLevelCode: string
Title:
Influence Level
Read Only:true
Maximum Length:30
The code indicating the influence the opportunity contact has on the buying process of the current opportunity. A list of accepted values is defined in the lookup HZ_SLS_CNTCT_INFLUENCE_LVL_CD. Review and update the value for this attribute using the Setup and Maintenance work area, Manage Contact Lookups task.
Nested Schema : Links
Type:
array
Title:
Links
The link relations associated with the resource instance.
Show Source
Nested Schema : link
Type:
Show Source
object
-
href: string
Title:
hyperlink reference
The URI to the related resource. -
kind: string
Title:
kind
Allowed Values:[ "collection", "item", "describe", "other" ]
The kind of the related resource. -
name: string
Title:
name
The name of the link to the related resource. -
properties: object
properties
-
rel: string
Title:
relation
Allowed Values:[ "self", "lov", "parent", "canonical", "child", "enclosure", "action", "custom" ]
The name of the relation to the resource instance. Example: self.
Nested Schema : properties
Type:
Show Source
object
-
changeIndicator: string
Change indicator or the ETag value of the resource instance.
Links
- OptyContactYesNoLOV
-
Parameters:
- finder:
LookupTypeFinder%3BBindLookupType%3DYES_NO
The lookups resource is used to view standard lookup codes. - finder:
- PreferredContactMethodLookupPVO
-
Parameters:
- finder:
LookupTypeActiveEnabledOrBindCodeFinder%3BBindLookupType%3DHZ_PREFERRED_CONTACT_METHOD%2CBindLookupCode%3D{PreferredContactMethod}
The lookups resource is used to view standard lookup codes. - finder:
- ZbsBuyingRoleTypesLOV
-
Parameters:
- finder:
LookupTypeActiveEnabledOrBindCodeFinder%3BBindLookupType%3DHZ_SLS_CNTCT_BUY_ROLE_CODE%2CBindLookupCode%3D{RoleCd}
The lookups resource is used to view standard lookup codes. - finder:
- ZbsContactAffinityTypesLOV
-
Parameters:
- finder:
LookupTypeActiveEnabledOrBindCodeFinder%3BBindLookupType%3DHZ_SLS_CNTCT_AFFINITY_CODE%2CBindLookupCode%3D{AffinityLvlCd}
The lookups resource is used to view standard lookup codes. - finder:
- ZbsInfluenceLevelTypesLOV
-
Parameters:
- finder:
LookupTypeActiveEnabledOrBindCodeFinder%3BBindLookupType%3DHZ_SLS_CNTCT_INFLUENCE_LVL_CD%2CBindLookupCode%3D{InfluenceLvlCd}
The lookups resource is used to view standard lookup codes. - finder:
Examples
The following example shows how to create an opportunity contact by submitting a post request on the REST resource using cURL.
cURL Command
curl -u <username:password> \ -X POST -d
@example_request_payload.json https://servername.fa.us2.oraclecloud.com/crmRestApi/resources/11.13.18.05/opportunities/CDRM_341580//child/OpportunityContact
Example of Request Body
The following shows an example of the request body in JSON format.
{ "PERPartyId": 100000016934214 }
Example of Response Body
The following shows an example of the response body in JSON format.
{ OptyConId: 300100092629899, CreatedBy: "MHoope", ContactedFlg: "N", CreationDate: "2016-11-17T05:54:14-08:00", OptyId: 300100092516122, PERPartyId: 100000016934214, PrimaryFlg: "N", PartyName: "Matt Baird", OptyConId: 300100092629899, EmailAddress: "mbaird@oracle.com", ContactPointId: 300100026717170, FormattedAddress: "South Avenue,MANHATTAN, NY 10005", FormattedPhoneNumber: "+1 (640) 345-3456 x6567", DoNotContactFlag: false, ContactPartyNumber: 100000016934213, ... }