Overview
The Social Media User service is used to store and manipulate social media user data, which can be harvested from social media channels. You can map the harvested social media users to Engagement Center customer accounts. This enables you to understand your customers better, based on their social media activities. The Social Media User service also provides the functionality of basic consent management. Make sure that the social media user data you stored in this service is fully compliant with all applicable laws and regulations. SAP does not accept any liability for the use of the service.
Using this service, you can:
- Retrieve social media users
- Store social media users
- Delete social media users
- Update social media users
API Reference
/{tenant}/socialMediaUsers
This resource defines the GET
, POST
methods for social media users.
/{tenant}/socialMediaUsers
Retrieve a list of social media users. If no query parameter is specified, a limited number of social media users will be returned. Using the query parameter q
, you can filter and get social media users with specific attributes. The GET
method is paged. Use the query parameter pageNumber
to control which page is retrieved. Use the query parameter pageSize
to control the number of social media users per page. The default pageSize
is 16.
Required scope: hybris.socialmediauser_view
Create a list of social media user items.
This method can be called to store the social media users harvested from your desired social media channels, and you can map the harvested social media users to Engagement Center customer accounts. If you can’t get all the required data from the social media channel directly, you may need to prepare them on your own before calling this method:
communicationMediumID
: The social media channel where the social media user is harvestedsocialMediaUserID
: The social media user identifier of the social media channelconsentGivenBy
: The person who confirms that the consent to store the social media user data is obtainedconsentGivenOn
: Time when the consent to create the social media user is givensocialMediaUserProfileLink
: URL to open the social media user profile directly on social media channelsocialMediaUserProfilePhotoLink
: The link of the social media user photo.country
: The country code restricted to ISO standard
Required scope: hybris.socialmediauser_manage
get /{tenant}/socialMediaUsers
Retrieve a list of social media users. If no query parameter is specified, a limited number of social media users will be returned. Using the query parameter q
, you can filter and get social media users with specific attributes. The GET
method is paged. Use the query parameter pageNumber
to control which page is retrieved. Use the query parameter pageSize
to control the number of social media users per page. The default pageSize
is 16.
Required scope: hybris.socialmediauser_view
URI Parameters
- tenant: required (string - minLength: 3 - maxLength: 16 - pattern: [a-z][a-z0-9]+)
The tenant (project or dev team) that the caller is acting upon. Note that this value is always lowercase.
Headers
- Authorization: required (string)
Used to send a valid OAuth2 access token.
Example:
Bearer access_token
Query Parameters
- pageNumber: (integer - default: 1 - minimum: 1)
The page number to be retrieved where the size of the pages must be specified by the pageSize parameter. The number of the first page is 1.
Example:
1
- pageSize: (integer - default: 16 - minimum: 1 - maximum: 64)
The number of documents being retrieved on the page.
Example:
16
- q: (string)
The simple query criteria based on available fields to limit returned results or a set of modified documents.
Example:
socialMediaUserID:"48857334"
HTTP status code 200
Social Media User retrieved successfully.
Headers
- Link: required (string - repeat: true)
Link to the current page, the next page and the previous page. Marked accordingly with rel self, rel next and rel prev. The syntax must be conform to RFC-5988. The link to the current page (self) is required and must be provided always. The link to the next page (next) is optional. If not present, the next page is not available, as the current page is the last page of the result. The link to the previous page (prev) is optional. If not present, the previous page is not available, as the current page is the first page of the result.
Example:
<http://sample.com?pageNumber=2&pageSize=10>; rel="self", <http://sample.com?pageNumber=3&pageSize=10>; rel="next"
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "Social Media User List",
"type": "array",
"items": {
"$schema": "http://json-schema.org/schema#",
"title": "Social Media User Schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier of the social media user item"
},
"communicationMediumID": {
"type": "string",
"description": "Social communication media ID"
},
"socialMediaUserID": {
"type": "string",
"description": "Unique identifier of the social user on the social media platform site"
},
"socialMediaUserAccountName": {
"type": "string",
"description": "Account Name of the social media user"
},
"socialMediaUserNickName": {
"type": "string",
"description": "Nick Name of the social media user"
},
"socialMediaEmail": {
"type": "string",
"description": "Email of social media user"
},
"creationDateTime": {
"type": "string",
"format": "date-time",
"description": "Creation time for social media user"
},
"socialMediaUserProfileLink": {
"type": "string",
"description": "URL to open the social media user profile directly on social media platform",
"format": "uri"
},
"socialMediaUserProfilePhotoLink": {
"type": "string",
"description": "URL to open the social media user profile photo directly on social media platform",
"format": "uri"
},
"consentGivenBy": {
"type": "string",
"description": "Person who provides the consent to create the social media user"
},
"consentGivenOn": {
"type": "string",
"format": "date-time",
"description": "Time when the consent to create the social media user is given"
},
"firstName": {
"type": "string",
"description": "First name"
},
"lastName": {
"type": "string",
"description": "Last name"
},
"fullName": {
"type": "string",
"description": "Full name"
},
"provider": {
"type": "string",
"description": "Provider"
},
"country": {
"type": "string",
"description": "Country",
"pattern": "[A-Z][A-Z]"
},
"referenceCustomerNumber": {
"type": "string",
"description": "Reference customer number of the social media user"
}
}
}
}
Example:
[
{
"id": "165423767",
"communicationMediumID": "SAP_COMMUNITY",
"socialMediaUserID": "1234567",
"socialMediaUserAccountName": "Mary",
"socialMediaUserNickName": "Sky",
"socialMediaEmail": "mary.smith@hybristest.com",
"creationDateTime": "2015-10-02T14:10:00.000+0000",
"socialMediaUserProfileLink": "www.facebook.com/useraccount/userprofile",
"socialMediaUserProfilePhotoLink": "www.facebook.com/useraccount/userprofile/photo.img",
"consentGivenOn": "2015-12-02T14:10:00.000+0000",
"consentGivenBy": "John Marker",
"firstName": "Mary",
"lastName": "Smith",
"fullName": "Mary Smith",
"provider": "WeChat",
"country": "CN",
"referenceCustomerNumber": "09876"
},
{
"id": "866433ggr",
"communicationMediumID": "FB",
"socialMediaUserID": "aaa",
"socialMediaUserAccountName": "Beck",
"socialMediaUserNickName": "Sky",
"socialMediaEmail": "mary.yang@hybristest.com",
"creationDateTime": "2015-10-03T14:10:00.000+0000",
"socialMediaUserProfileLink": "www.facebook.com/useraccount/userprofile",
"socialMediaUserProfilePhotoLink": "www.facebook.com/useraccount/userprofile/photo.img",
"consentGivenOn": "2015-10-09T14:10:00.000+0000",
"consentGivenBy": "Sky Wang",
"firstName": "Christina",
"lastName": "Troefan",
"fullName": "Christina Troefan",
"provider": "Facebook",
"country": "CN",
"referenceCustomerNumber": "09876"
},
{
"id": "di394749djl3",
"communicationMediumID": "FB",
"socialMediaUserID": "bbb",
"socialMediaUserAccountName": "colin",
"socialMediaUserNickName": "Sky",
"socialMediaEmail": "mary.yang@hybristest.com",
"creationDateTime": "2015-10-02T14:10:00.000+0000",
"socialMediaUserProfileLink": "www.facebook.com/useraccount/userprofile",
"socialMediaUserProfilePhotoLink": "www.facebook.com/useraccount/userprofile/photo.img",
"consentGivenOn": "2015-10-22T14:10:00.000+0000",
"consentGivenBy": "Lucy hamber",
"firstName": "Lucy",
"lastName": "hamber",
"fullName": "Lucy hamber",
"provider": "Facebook",
"country": "UN",
"referenceCustomerNumber": "09876"
}
]
HTTP status code 400
Request syntactically incorrect. Any details will be provided within the response payload.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Example:
{
"status": 400,
"message": "There are validation problems, see details section for more information",
"moreInfo": "https://api.yaas.io/patterns/errortypes.html",
"type": "validation_violation",
"details": [
{
"field": "q",
"message": "not a valid query",
"type": "invalid_query_parameter"
}
]
}
HTTP status code 401
Given request is unauthorized. Bad or expired token. Reauthenticate the user. Any details will be provided within the response payload.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Example:
{
"status": 401,
"message": "Authorization: Unauthorized. Bearer TOKEN is invalid",
"type": "insufficient_credentials",
"moreInfo": "https://api.yaas.io/patterns/errortypes.html"
}
HTTP status code 403
Evaluated request scopes in access token are not sufficient and do not match required scopes.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Example:
{
"status": 403,
"message": "Given request does not have required scopes in access token. It is not authorized to perform this operation.",
"type": "insufficient_permissions"
}
HTTP status code 404
The requested resource does not exist.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 409
The request could not be completed due to a conflict with the current state of the resource.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 500
Internal Server Error
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 503
Service temporarily unavailable.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
post /{tenant}/socialMediaUsers
Create a list of social media user items.
This method can be called to store the social media users harvested from your desired social media channels, and you can map the harvested social media users to Engagement Center customer accounts. If you can’t get all the required data from the social media channel directly, you may need to prepare them on your own before calling this method:
communicationMediumID
: The social media channel where the social media user is harvestedsocialMediaUserID
: The social media user identifier of the social media channelconsentGivenBy
: The person who confirms that the consent to store the social media user data is obtainedconsentGivenOn
: Time when the consent to create the social media user is givensocialMediaUserProfileLink
: URL to open the social media user profile directly on social media channelsocialMediaUserProfilePhotoLink
: The link of the social media user photo.country
: The country code restricted to ISO standard
Required scope: hybris.socialmediauser_manage
URI Parameters
- tenant: required (string - minLength: 3 - maxLength: 16 - pattern: [a-z][a-z0-9]+)
The tenant (project or dev team) that the caller is acting upon. Note that this value is always lowercase.
Headers
- Authorization: required (string)
Used to send a valid OAuth2 access token.
Example:
Bearer access_token
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/schema#",
"title": "Social media user schema for use with post",
"type": "object",
"properties": {
"communicationMediumID": {
"type": "string",
"description": "Social communication media ID"
},
"socialMediaUserID": {
"type": "string",
"description": "Unique identifier of the social user on the social media platform site"
},
"socialMediaUserAccountName": {
"type": "string",
"description": "Account Name of the social media user"
},
"socialMediaUserNickName": {
"type": "string",
"description": "Nick Name of the social media user"
},
"socialMediaEmail": {
"type": "string",
"description": "Email of social media user"
},
"creationDateTime": {
"type": "string",
"format": "date-time",
"description": "Creation time for social media user"
},
"socialMediaUserProfileLink": {
"type": "string",
"description": "URL to open the social media user profile directly on social media platform",
"format": "uri"
},
"socialMediaUserProfilePhotoLink": {
"type": "string",
"description": "URL to open the social media user profile photo directly on social media platform",
"format": "uri"
},
"consentGivenBy": {
"type": "string",
"description": "Person who provides the consent to create the social media user"
},
"consentGivenOn": {
"type": "string",
"format": "date-time",
"description": "Time when the consent to create the social media user is given"
},
"firstName": {
"type": "string",
"description": "First name"
},
"lastName": {
"type": "string",
"description": "Last name"
},
"fullName": {
"type": "string",
"description": "Full name"
},
"provider": {
"type": "string",
"description": "Provider"
},
"country": {
"type": "string",
"description": "Country"
},
"referenceCustomerNumber": {
"type": "string",
"description": "Reference customer number of the social media user"
}
},
"required": [
"communicationMediumID",
"socialMediaUserID",
"consentGivenOn",
"consentGivenBy"
]
}
Example:
{
"communicationMediumID": "SAP_COMMUNITY",
"socialMediaUserID": "1234567",
"socialMediaUserAccountName": "Mary",
"socialMediaUserNickName": "Sky",
"socialMediaEmail": "mary.smith@hybristest.com",
"creationDateTime": "2015-10-02T14:10:00.000+0000",
"socialMediaUserProfileLink": "www.facebook.com/useraccount/userprofile",
"socialMediaUserProfilePhotoLink": "www.facebook.com/useraccount/userprofile/photo.img",
"consentGivenOn": "2015-12-02T14:10:00.000+0000",
"consentGivenBy": "John Marker",
"firstName": "Mary",
"lastName": "Smith",
"fullName": "Mary Smith",
"provider": "Twitter",
"country": "CN",
"referenceCustomerNumber": "09876"
}
HTTP status code 201
The social media user has been successfully created.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"title": "Resource Location",
"description": "Schema for showing location of the new social media user",
"properties": {
"id": {
"description": "The identifier of the social media user",
"type": "string"
},
"link": {
"description": "The link to the created social media user",
"type": "string",
"format": "uri"
}
},
"required": [
"id",
"link"
]
}
Example:
[
{
"id": "54d1df314b4e9a3a90135790123",
"link": "https://api.beta.yaas.io/repository/v2/test/test/data/socialMediaUsers/54d1df314b4e9a3a90135790123"
}
]
HTTP status code 400
Request syntactically incorrect. Any details will be provided within the response payload.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 401
Given request is unauthorized. Bad or expired token. Reauthenticate the user. Any details will be provided within the response payload.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Example:
{
"status": 401,
"message": "Authorization: Unauthorized. Bearer TOKEN is invalid",
"type": "insufficient_credentials",
"moreInfo": "https://api.yaas.io/patterns/errortypes.html"
}
HTTP status code 403
Evaluated request scopes in access token are not sufficient and do not match required scopes.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Example:
{
"status": 403,
"message": "Given request does not have required scopes in access token. It is not authorized to perform this operation.",
"type": "insufficient_permissions"
}
HTTP status code 404
The requested resource does not exist.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 409
The request could not be completed due to a conflict with the current state of the resource.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 500
Internal Server Error
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 503
Service temporarily unavailable.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
/{tenant}/socialMediaUsers/{id}
This resource defines the GET
, PUT
and DELETE
methods for individual social media user.
Get a social media user item.
Retrieve an individual social media user by the its specific id
.
Required scope: hybris.socialmediauser_view
Update an existing social media user item.
Update a social media user item with its identified id
.
You can't update follow data fields when calling this method:
communicationMediumID
: The social media channel where the social media user is harvestedsocialMediaUserID
: The social media user identifier of the social media channel
If you try to update the following data fields with empty value when calling this method, we will keep these two fields with the old values:
consentGivenBy
: The person who confirms that the consent to store the social media user data is obtainedconsentGivenOn
: Time when the consent to create the social media user is given
Required scope: hybris.socialmediauser_manage
Delete a social media user item.
The social media user to be deleted is identified by its id
.
Required scope: hybris.socialmediauser_delete
get /{tenant}/socialMediaUsers/{id}
Get a social media user item.
Retrieve an individual social media user by the its specific id
.
Required scope: hybris.socialmediauser_view
URI Parameters
- tenant: required (string - minLength: 3 - maxLength: 16 - pattern: [a-z][a-z0-9]+)
The tenant (project or dev team) that the caller is acting upon. Note that this value is always lowercase.
- id: required (string)
Example:
56dd511bf0e0a6001ddca1bc
Headers
- Authorization: required (string)
Used to send a valid OAuth2 access token.
Example:
Bearer access_token
HTTP status code 200
Social media user has been successfully retrieved.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/schema#",
"title": "Social Media User Schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier of the social media user item"
},
"communicationMediumID": {
"type": "string",
"description": "Social communication media ID"
},
"socialMediaUserID": {
"type": "string",
"description": "Unique identifier of the social user on the social media platform site"
},
"socialMediaUserAccountName": {
"type": "string",
"description": "Account Name of the social media user"
},
"socialMediaUserNickName": {
"type": "string",
"description": "Nick Name of the social media user"
},
"socialMediaEmail": {
"type": "string",
"description": "Email of social media user"
},
"creationDateTime": {
"type": "string",
"format": "date-time",
"description": "Creation time for social media user"
},
"socialMediaUserProfileLink": {
"type": "string",
"description": "URL to open the social media user profile directly on social media platform",
"format": "uri"
},
"socialMediaUserProfilePhotoLink": {
"type": "string",
"description": "URL to open the social media user profile photo directly on social media platform",
"format": "uri"
},
"consentGivenBy": {
"type": "string",
"description": "Person who provides the consent to create the social media user"
},
"consentGivenOn": {
"type": "string",
"format": "date-time",
"description": "Time when the consent to create the social media user is given"
},
"firstName": {
"type": "string",
"description": "First name"
},
"lastName": {
"type": "string",
"description": "Last name"
},
"fullName": {
"type": "string",
"description": "Full name"
},
"provider": {
"type": "string",
"description": "Provider"
},
"country": {
"type": "string",
"description": "Country",
"pattern": "[A-Z][A-Z]"
},
"referenceCustomerNumber": {
"type": "string",
"description": "Reference customer number of the social media user"
}
}
}
Example:
{
"id": "56d7fcffa80d1d001d27cb2f",
"communicationMediumID": "SAP_COMMUNITY",
"socialMediaUserID": "1234567",
"socialMediaUserAccountName": "Mary",
"socialMediaUserNickName": "Sky",
"socialMediaEmail": "mary.smith@hybristest.com",
"creationDateTime": "2015-10-02T14:10:00.000+0000",
"socialMediaUserProfileLink": "www.facebook.com/useraccount/userprofile",
"socialMediaUserProfilePhotoLink": "www.facebook.com/useraccount/userprofile/photo.img",
"consentGivenOn": "2015-12-02T14:10:00.000+0000",
"consentGivenBy": "John Marker",
"firstName": "Mary",
"lastName": "Smith",
"fullName": "Mary Smith",
"provider": "WeChat",
"country": "CN",
"referenceCustomerNumber": "09876"
}
HTTP status code 400
Request syntactically incorrect. Any details will be provided within the response payload.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 401
Given request is unauthorized. Bad or expired token. Reauthenticate the user. Any details will be provided within the response payload.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Example:
{
"status": 401,
"message": "Authorization: Unauthorized. Bearer TOKEN is invalid",
"type": "insufficient_credentials",
"moreInfo": "https://api.yaas.io/patterns/errortypes.html"
}
HTTP status code 403
Evaluated request scopes in access token are not sufficient and do not match required scopes.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Example:
{
"status": 403,
"message": "Given request does not have required scopes in access token. It is not authorized to perform this operation.",
"type": "insufficient_permissions"
}
HTTP status code 404
The requested resource does not exist.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 409
The request could not be completed due to a conflict with the current state of the resource.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 500
Internal Server Error
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 503
Service temporarily unavailable.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
put /{tenant}/socialMediaUsers/{id}
Update an existing social media user item.
Update a social media user item with its identified id
.
You can't update follow data fields when calling this method:
communicationMediumID
: The social media channel where the social media user is harvestedsocialMediaUserID
: The social media user identifier of the social media channel
If you try to update the following data fields with empty value when calling this method, we will keep these two fields with the old values:
consentGivenBy
: The person who confirms that the consent to store the social media user data is obtainedconsentGivenOn
: Time when the consent to create the social media user is given
Required scope: hybris.socialmediauser_manage
URI Parameters
- tenant: required (string - minLength: 3 - maxLength: 16 - pattern: [a-z][a-z0-9]+)
The tenant (project or dev team) that the caller is acting upon. Note that this value is always lowercase.
- id: required (string)
Example:
56dd511bf0e0a6001ddca1bc
Headers
- Authorization: required (string)
Used to send a valid OAuth2 access token.
Example:
Bearer access_token
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/schema#",
"title": "Social Media User Schema",
"type": "object",
"properties": {
"socialMediaUserAccountName": {
"type": "string",
"description": "Account Name of the social media user"
},
"socialMediaUserNickName": {
"type": "string",
"description": "Nick Name of the social media user"
},
"socialMediaEmail": {
"type": "string",
"description": "Email of social media user"
},
"creationDateTime": {
"type": "string",
"format": "date-time",
"description": "Creation time for social media user"
},
"socialMediaUserProfileLink": {
"type": "string",
"description": "URL to open the social media user profile directly on social media platform",
"format": "uri"
},
"socialMediaUserProfilePhotoLink": {
"type": "string",
"description": "URL to open the social media user profile photo directly on social media platform",
"format": "uri"
},
"consentGivenBy": {
"type": "string",
"description": "Person who provides the consent to create the social media user"
},
"consentGivenOn": {
"type": "string",
"format": "date-time",
"description": "Time when the consent to create the social media user is given"
},
"firstName": {
"type": "string",
"description": "First name"
},
"lastName": {
"type": "string",
"description": "Last name"
},
"fullName": {
"type": "string",
"description": "Full name"
},
"provider": {
"type": "string",
"description": "Provider"
},
"country": {
"type": "string",
"description": "Country",
"pattern": "[A-Z][A-Z]"
},
"referenceCustomerNumber": {
"type": "string",
"description": "Reference customer number of the social media user"
}
},
"required": [
"consentGivenOn",
"consentGivenBy"
]
}
Example:
{
"socialMediaUserAccountName": "Mary",
"socialMediaUserNickName": "Sky",
"socialMediaEmail": "mary.smith@hybristest.com",
"creationDateTime": "2015-10-02T14:10:00.000+0000",
"socialMediaUserProfileLink": "www.facebook.com/useraccount/userprofile",
"socialMediaUserProfilePhotoLink": "www.facebook.com/useraccount/userprofile/photo.img",
"consentGivenOn": "2015-12-02T14:10:00.000+0000",
"consentGivenBy": "John Marker",
"firstName": "Mary",
"lastName": "Smith",
"fullName": "Mary Smith",
"provider": "Twitter",
"country": "CN",
"referenceCustomerNumber": "09876"
}
HTTP status code 204
Social media user has been successfully updated.
HTTP status code 400
Request syntactically incorrect. Any details will be provided within the response payload.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 401
Given request is unauthorized. Bad or expired token. Reauthenticate the user. Any details will be provided within the response payload.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Example:
{
"status": 401,
"message": "Authorization: Unauthorized. Bearer TOKEN is invalid",
"type": "insufficient_credentials",
"moreInfo": "https://api.yaas.io/patterns/errortypes.html"
}
HTTP status code 403
Evaluated request scopes in access token are not sufficient and do not match required scopes.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Example:
{
"status": 403,
"message": "Given request does not have required scopes in access token. It is not authorized to perform this operation.",
"type": "insufficient_permissions"
}
HTTP status code 404
The requested resource does not exist.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 409
The request could not be completed due to a conflict with the current state of the resource.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 500
Internal Server Error
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 503
Service temporarily unavailable.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
delete /{tenant}/socialMediaUsers/{id}
Delete a social media user item.
The social media user to be deleted is identified by its id
.
Required scope: hybris.socialmediauser_delete
URI Parameters
- tenant: required (string - minLength: 3 - maxLength: 16 - pattern: [a-z][a-z0-9]+)
The tenant (project or dev team) that the caller is acting upon. Note that this value is always lowercase.
- id: required (string)
Example:
56dd511bf0e0a6001ddca1bc
Headers
- Authorization: required (string)
Used to send a valid OAuth2 access token.
Example:
Bearer access_token
HTTP status code 204
Social media user has been successfully deleted.
HTTP status code 400
Request syntactically incorrect. Any details will be provided within the response payload.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 401
Given request is unauthorized. Bad or expired token. Reauthenticate the user. Any details will be provided within the response payload.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Example:
{
"status": 401,
"message": "Authorization: Unauthorized. Bearer TOKEN is invalid",
"type": "insufficient_credentials",
"moreInfo": "https://api.yaas.io/patterns/errortypes.html"
}
HTTP status code 403
Evaluated request scopes in access token are not sufficient and do not match required scopes.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Example:
{
"status": 403,
"message": "Given request does not have required scopes in access token. It is not authorized to perform this operation.",
"type": "insufficient_permissions"
}
HTTP status code 404
The requested resource does not exist.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 409
The request could not be completed due to a conflict with the current state of the resource.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 500
Internal Server Error
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
HTTP status code 503
Service temporarily unavailable.
Body
Type: application/json
Schema:
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "error",
"description": "Schema for API specified errors.",
"type": "object",
"properties": {
"status": {
"type": "integer",
"description": "original HTTP error code, should be consistent with the response HTTP code",
"minimum": 100,
"maximum": 599
},
"type": {
"type": "string",
"description": "classification of the error type, lower case with underscore eg validation_failure",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support"
},
"details": {
"type": "array",
"description": "list of problems causing this error",
"items": {
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "errorDetail",
"description": "schema for specific error cause",
"type": "object",
"properties": {
"field": {
"type": "string",
"description": "a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific"
},
"type": {
"type": "string",
"description": "classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.",
"pattern": "[a-z]+[a-z_]*[a-z]+"
},
"message": {
"type": "string",
"description": "descriptive error detail message for debugging"
},
"moreInfo": {
"type": "string",
"format": "uri",
"description": "link to documentation to investigate further and finding support for error detail"
}
},
"required": [
"type"
]
}
}
},
"required": [
"status",
"type"
]
}
Scopes
The table shows the scopes that the Social Media User service supports.
SCOPE | DESCRIPTION |
---|---|
hybris.socialmediauser_view | Read-only access to social media user data |
hybris.socialmediauser_delete | Delete social media user data |
hybris.socialmediauser_manage | Create and update social media user data |
For more information about scopes, authorization, and authentication procedures for YaaS services, see Scopes and Authorization.
Prerequisites
To manage social media users derived from the corresponding social media channels, store the user data and map the user data to a customer account. You must obtain the user’s consent, according to the laws and regulations concerning private data and protection.
Management of Social Media Users
You can use the resource socialMediaUsers to manage the social media users derived from the corresponding social media channels, such as Facebook, Twitter, and SAP Jam Communities. To use this feature, you must define the social media channels from which to derive social media user data. Do this in the Social Media Settings Builder module.
Social Media User Creation
To create a social media user, you must specify the social media channel and the social media user ID.
These attributes are mandatory when creating a social media user:
- communicationMediumID
- socialMediaUserID (refers to one particular user in connection to one particular communication channel)
- consentGivenOn (see the Prerequisites section)
- consentGivenBy (see the Prerequisites section)
For more information about creating social media users, see Create Social Media User.
Social Media User Update
You can update the attributes of the social media user, by using the attribute id.
These attributes cannot be changed after you create the social media user:
- id refers to one particular user. The Social Media User service generates the ID when you create a social media user.
- communicationMediumID
- socialMediaUserID refers to one particular user in connection with one particular communication channel.
For more information about updating social media users, see Update a Social Media User.
Social Media User Retrieval
You can retrieve existing social media users by using a query to find one or more users, or by retrieving a single social media user by id.
Retrieve multiple social media users
You can use query parameters to retrieve social media users. These attributes are unique and only apply to one user:
- id
- socialMediaUserID within one communicationMediumID
For more information about retrieving multiple social media users, see Search Social Media Users.
Retrieve social media user by ID
After a social media user is created, the service generates an id for it. You can use the id to search for the individual social media user.
For more information, see Retrieve Social Media User.
Customer Account Mapping
To map the social media user to a customer account, specify the value of the attribute referenceCustomerNumber in the social media user data. The attribute represents the customer account ID that is linked to the social media user.
You can link several social media users to the same account by assigning the identical referenceCustomerNumber to the appropriate social media users.
To remove the mapping between a social media user and a customer account, you must set the referenceCustomerNumber to NULL
.
For more information, see Update a Social Media User.
Create Social Media User
Request
To create a social media user, use the information shown to perform the request.
- Method: POST
- Request URL:
https://api.beta.yaas.io/hybris/socialmediauser/v1/{tenant}/socialMediaUsers
- Headers
- Authorization: This includes a valid OAuth2 access token. To access this method, the access token must be issued for the requested tenant and have the scope hybris.socialmediauser_manage.
- URI Parameters
- {tenant}: The name of the current tenant
- Body: The mandatory attributes include communicationMediumID, socialMediaUserID, consentGivenBy, and consentGivenOn.
{ "communicationMediumID":"SAP_COMMUNITY", "socialMediaUserID":"1234567", "socialMediaUserAccountName":"Mary", "socialMediaUserNickName":"Sky", "socialMediaEmail":"mary.smith@hybristest.com", "creationDateTime":"2015-10-02T14:10:00.000+0000", "socialMediaUserProfileLink":"www.facebook.com/useraccount/userprofile", "socialMediaUserProfilePhotoLink":"www.facebook.com/useraccount/userprofile/photo.img", "consentGivenOn":"2015-12-02T14:10:00.000+0000", "consentGivenBy":"John Marker", "firstName":"Mary", "lastName":"Smith", "fullName":"Mary Smith", "provider":"Twitter", "country":"CN", "referenceCustomerNumber":"09876" }
Response
The successful response returns a 201
status code. An example JSON content looks similar to the following:
{
"id":"54d1df314b4e9a3a90135790123",
"link":"https://api.beta.yaas.io/repository/v2/test/test/data/socialMediaUsers/54d1df314b4e9a3a90135790123"
}
Retrieve Social Media User
You can retrieve the details of a social media user by using the unique id the system generates for each social media user.
The request body does not need to contain any information. The service sends the required data together with the URI parameters and the headers.
The example provided shows how to retrieve a social media user by using the unique id.
You can retrieve the social media user details by using the request information shown:
Request
- Method: GET
- Request URL:
https://api.beta.yaas.io/hybris/socialmediauser/v1/{tenant}/socialMediaUsers/{id}
- Headers
- Authorization: This includes a valid OAuth2 access token. To access this method, the access token must be issued for the requested tenant and have the scope hybris.socialmediauser_view.
- URI Parameters
- {tenant}: The name of the current tenant
- {id}: The unique identifier of the social media user
Response
The successful response returns a 200
status code. An example JSON content looks similar to the following:
{
"id": "56d7fcffa80d1d001d27cb2f",
"communicationMediumID":"SAP_COMMUNITY",
"socialMediaUserID":"1234567",
"socialMediaUserAccountName":"Mary",
"socialMediaUserNickName":"Sky",
"socialMediaEmail":"mary.smith@hybristest.com",
"creationDateTime":"2015-10-02T14:10:00.000+0000",
"socialMediaUserProfileLink":"www.facebook.com/useraccount/userprofile",
"socialMediaUserProfilePhotoLink":"www.facebook.com/useraccount/userprofile/photo.img",
"consentGivenOn":"2015-12-02T14:10:00.000+0000",
"consentGivenBy":"John Marker",
"firstName":"Mary",
"lastName":"Smith",
"fullName":"Mary Smith",
"provider":"WeChat",
"country":"CN",
"referenceCustomerNumber":"09876"
}
Search Social Media Users
You can search for relevant social media users by specifying query parameters, such as specific attributes. This example shows how to search for social media users by specifying attributes as query parameters.
To search for social media users, use the information shown to perform the request:
Request
- Method: GET
- Request URL:
https://api.beta.yaas.io/hybris/socialmediauser/v1/{tenant}/socialMediaUsers
- Headers
- Authorization: This includes a valid OAuth2 access token. To access this method, the access token must be issued for the requested tenant and have the scope hybris.socialmediauser_view.
- URI Parameters
- {tenant}: The name of the current tenant
- Query Parameters
- Use PageNumber to control which page is retrieved. Page numbering starts with
1
. - Use PageSize to control the number of social media users per page.
- q stands for specific attributes. For example,
socialMediaUserID:48857334
andreferenceCustomerNumber:09876
.
- Use PageNumber to control which page is retrieved. Page numbering starts with
Query parameters are not mandatory. If no query parameter is specified, a limited number of social media users is returned.
Response
The successful response returns a 200
status code. An example JSON content looks similar to the following:
[
{
"id": "56d7fcffa80d1d001d27cb2f",
"communicationMediumID":"SAP_COMMUNITY",
"socialMediaUserID":"1234567",
"socialMediaUserAccountName":"Mary",
"socialMediaUserNickName":"Sky",
"socialMediaEmail":"mary.smith@hybristest.com",
"creationDateTime":"2015-10-02T14:10:00.000+0000",
"socialMediaUserProfileLink":"www.facebook.com/useraccount/userprofile",
"socialMediaUserProfilePhotoLink":"www.facebook.com/useraccount/userprofile/photo.img",
"consentGivenOn":"2015-12-02T14:10:00.000+0000",
"consentGivenBy":"John Marker",
"firstName":"Mary",
"lastName":"Smith",
"fullName":"Mary Smith",
"provider":"WeChat",
"country":"CN",
"referenceCustomerNumber":"09876"
},
{
"id": "56d7fcffa80d18001d27cb2f",
"communicationMediumID":"SAP_COMMUNITY",
"socialMediaUserID":"7654321",
"socialMediaUserAccountName":"John",
"socialMediaUserNickName":"Blue",
"socialMediaEmail":"john.smith@hybristest.com",
"creationDateTime":"2016-10-08T14:09:00.000+0000",
"socialMediaUserProfileLink":"www.facebook.com/useraccount/userprofile",
"socialMediaUserProfilePhotoLink":"www.facebook.com/useraccount/userprofile/photo.img",
"consentGivenOn":"2016-12-03T14:10:00.000+0000",
"consentGivenBy":"John Marker",
"firstName":"John",
"lastName":"Smith",
"fullName":"John Smith",
"provider":"WeChat",
"country":"CN",
"referenceCustomerNumber":"09815"
}
]
Update a Social Media User
You can modify social media user attributes, with the exception of id, communicationMediumID, and socialMediaUserID.
Follow this example to update a social media user by id:
Request
- Method: PUT
- Request URL:
https://api.beta.yaas.io/hybris/socialmediauser/v1/{tenant}/socialMediaUsers/{id}
- Headers
- Authorization: This includes a valid OAuth2 access token. To access this method, the access token must be issued for the requested tenant and have the scope hybris.socialmediauser_manage.
- URI Parameters
- {tenant}: The name of the current tenant
- {id}: The unique identifier of the social media user
Body: The request body must contain the consentGivenBy and consentGivenOn attributes.
Properties of an existing social media user:
{ "id":"58088245e7d599001dea4329", "socialMediaUserID": "123s32d4567", "socialMediaUserAccountName":"Mary", "socialMediaUserNickName":"Sky", "socialMediaEmail":"mary.smith@hybristest.com", "creationDateTime":"2015-10-02T14:10:00.000+0000", "socialMediaUserProfileLink":"www.facebook.com/useraccount/userprofile", "socialMediaUserProfilePhotoLink":"www.facebook.com/useraccount/userprofile/photo.img", "consentGivenOn":"2015-12-02T14:10:00.000+0000", "consentGivenBy":"John Marker", "communicationMediumID": "SAP_COMMUNITY", "firstName":"Mary", "lastName":"Smith", "fullName":"Mary Smith", "provider":"Twitter", "country":"CN", "referenceCustomerNumber":"09876" }
To change the attributes for the social media user, you need to send a request that includes the properties to be changed. The remaining attributes must be included in the request with the original values.
{ "socialMediaUserAccountName":"Mary lee", "consentGivenOn":"2015-12-02T14:10:00.000+0000", "consentGivenBy":"John Marker" }
If you retrieve this user's data now, the properties are modified. Note that you cannot update the id, communicationMediumID, or socialMediaUserID by calling PUT method.
{ "communicationMediumID": "SAP_COMMUNITY", "consentGivenOn":"2015-12-02T14:10:00.000+0000", "consentGivenBy":"John Marker", "id":"58088245e7d599001dea4329", "socialMediaUserAccountName":"Mary lee", "socialMediaUserID": "123s32d4567" }
The successful response returns a 204
status code.
Delete a Social Media User
The Social Media User service allows you delete a social media user by user id.
To delete a social media user, use the information shown to perform the request:
Request
- Method: DELETE
- Request URL:
https://api.beta.yaas.io/hybris/socialmediauser/v1/{tenant}/socialMediaUsers/{id}
- Headers
- Authorization: This includes a valid OAuth2 access token. To access this method, the access token must be issued for the requested tenant and have the scope hybris.socialmediauser_delete.
- URI Parameters
- {tenant}: The name of the current tenant
- {id}: The unique identifier of the social media user
Response
The successful response returns a 204
status code.
Error Types
For information about error codes, see the API Reference.
Glossary
Term | Description |
---|---|
Engagement Center customer account | A user that an agent can identify in the Engagement Center. |
If you find any information that is unclear or incorrect, please let us know so that we can improve the Dev Portal content.
Use our private help channel. Receive updates over email and contact our specialists directly.
If you need more information about this topic, visit hybris Experts to post your own question and interact with our community and experts.