Can someday jump on this and help me to update the ticket field (ticket is already submitted), the targeted field is a custom-field which I need to update it using the Zendesk API,
Can this is possible using Zendesk API?
Thank You
Update - Using Zendesk Api Endpoint
Zendesk Api Update Ticket is what you need to hit with the payload as described here:
{
ticket: {
custom_fields: [{ "id": 25356371, "value": "something"}]
}
}
Old Answer (using zafClient)
If you're trying this from Sidebar app and utilizing zafClient then its pretty straightforward. Example here and below
client.set('ticket.customField:fieldName', value)
If you're trying this with Zendesk rest api then you can utilize this Update Ticket endpoint to update the value of any Custom-Field present in that ticket.
Steps to update:
get custom-field's id
get ticket id
Hit update ticket api with following JSON payload
{
ticket: {
custom_fields: [{id: <custom_field_id>, value: 'hurray!'}]
},
}
Related
How to fetch integrated versions field present in Jira ticket via REST API?
Your Integrated Version field is probably a custom field based on project version. The field is identified by its ID (e.g. customfield_10500).
If you use common REST API method to retrieve a Jira issue, you can see the field in the JSON response:
https://jira.domain.com/rest/api/2/issue/TEST-123
"fields": {
...
"customfield_10500": [
{
"self": "https://jira.domain.com/rest/api/2/version/21787",
"id": "21787",
"name": "8.0.3.0",
"archived": false,
"released": false
}
],
...
}
You can limit the request to get only that specific custom field only:
https://jira.domain.com/rest/api/2/issue/TEST-123?fields=customfield_10500
To retrieve all available project versions, you need to retrieve all project versions: https://docs.atlassian.com/software/jira/docs/api/REST/8.5.13/#api/2/project-getProjectVersions
fixVersion is a part of a Jira issue. So for that purposes it's possible to get using get issue rest request.
Here's a reference from atlassian doc: https://docs.atlassian.com/software/jira/docs/api/REST/8.5.13/#api/2/issue-getIssue
To grab only fixVersion field and its data, it will look like:
https://jira_url/rest/api/2/issue/$ISSUE_KEY?fields=fixVersions
I am trying to create a new incident through postman in Dynamics CRM but I am getting the following error:
You should specify a parent contact or account
Which I assumed that is asking for customerid to be sent so I added it on postman like:
{
"description": "Test",
"ed_egresssenttorentadmin": true,
"note['_customerid_value#odata.bind']":"f686f062-e542-e811-a955-000d3ab27a43",
"note['_ownerid_value#odata.bind']":"a7b7fcb7-a64e-e811-a96f-000d3ab384bc"
}
but I still get the same error, any idea on how to set accountId when creating a new incident ?
According to RESTBuilder it should look something like this.
entity["customerid_account#odata.bind"] = "/accounts(f686f062-e542-e811-a955-000d3ab27a43)"
Actually this is the basic payload needed to create an incident:
{
"title": "case test",
"customerid_account#odata.bind": "/accounts(f686f062-e542-e811-a955-000d3ab27a43)"
}
On my website I have a contact form which when submitted, creates a new service desk ticket. It makes the following rest api call:
https://jira-housters.atlassian.net/rest/servicedeskapi/request (with appropriate Accept and Authorization request headers)
{
"serviceDeskId": "1",
"requestTypeId": "1",
"requestFieldValues": {
"summary": "Housters Contact from Justin Test (Web)",
"description": "test message"
},
"raiseOnBehalfOf": "myemail#mydomain.com"
}
Before this worked completely fine, however a few days ago it started erroring:
{"errorMessage":"Your request could not be created. Please check the fields have been correctly filled in. Please provide a valid value for field 'Raise this request on behalf of'","i18nErrorMessage":{"i18nKey":"sd.validation.request.creation.failure.required.field","parameters":["Please provide a valid value for field 'Raise this request on behalf of'"]}}
This makes no sense, as it's complaining about the raise request on behalf of field when I clearly have it specified. What gives?
raiseOnBehalfOf should have the customers accountId not email.
You can create a customer using:-
-> https://your-domain.atlassian.net/rest/servicedeskapi/customer
-> Get the accountId from the response.
A Post entity (https://msdn.microsoft.com/en-us/library/mt607553.aspx) cannot be created using Dynamics CRM 2016 Online Web API.
This payload should create a post on POST /api/data/v8.1/posts
{
"text": "Test Single Post",
"source": 1,
"type": 7
}
(source 1 is an auto post, type 7 is a status post)
But it returns:
{
"error":
{
"code":"",
"message":"An unexpected error occurred.",
"innererror"
{
"message":"An unexpected error occurred..."
}
}
}
Submitting the same payload with only "text" fails too.
Notice that the Post entity does not have single-valued navigation properties (https://msdn.microsoft.com/en-us/library/mt607553.aspx#bkmk_SingleValuedNavigationProperties) that will allow me to set the related entity (contact, account, etc).
For example, Creating a Task entity (https://msdn.microsoft.com/en-us/library/mt607619.aspx) works fine on POST /api/data/v8.1/tasks
{
"subject": "Test Single Task",
"description": "Test One Description of Task",
"regardingobjectid_contact_task#odata.bind": "/contacts(<someguid>)",
"scheduledend": "2016-07-21T12:11:19.4875892Z"
}
It seems to me that Post should expose something like regardingobjectid_contact_post#odata.bind, but it does not.
For context, this is how to create a Post via the SOAP endpoint and the SDK:
var result = Client.getOrganizationService().Create(new Post
{
Text = post.text,
RegardingObjectId = new EntityReference(
entityName,
Guid.Parse(post.regarding_guid)
)
});
Does anyone have a working example of a Post created via the Web API? Is this an omission in the Dynamics CRM Web API?
It doesn't look like this is listed in the limitations: https://msdn.microsoft.com/en-us/library/mt628816.aspx
UPDATE
It appears that the postregarding entity is where the link should be created to contact/account. This can be demonstrated by querying:
/posts?$filter=postregardingid/regardingobjectid_contact/contactid eq <someguid>
However, a "deep insert" like so does not work:
{
"text":"sometext",
"postregardingid":
{
"regardingobjectid_contact#odata.bind":"/contacts(someguid)"
}
}
The response is
Cannot create child entities before parent entity.
Nowhere it's mentioned like Post (activity feed) cannot be created using webapi. In fact it's not listed as crm webapi limitation like you pointed out.
Also on comparison, _regardingobjectid_value lookup property of post is different from activitypointer. Single valued navigation property too.
Out of curiosity, My investigation moved towards the Partner - post_PostRegardings
Only thing making sense - postregarding is strictly internal use. This could be the reason for all such behavior. This is my theory per v8.2 today(Aug 12 2017)
Description: Represents which object an activity feed post is regarding. For internal use only.
Entity Set path:[organization URI]/api/data/v8.2/postregardings
Base Type: crmbaseentity EntityType
Display Name: Post Regarding
Primary Key: postregardingid
Ref: https://msdn.microsoft.com/en-us/library/mt608103.aspx
Update:
Looks like MS recommend the community to use Organization service to create a custom Post record. Web api is still broken. Read more
I was recently struggling with this issue with an Activity table made using powerapps. For those who are interested, here's my post request:
POST: https://<MY_DOMAIN>.crm.dynamics.com/api/data/v9.1/<TABLE_NAME>
{
"regardingobjectid_contact#odata.bind": "/contacts(xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)",
"description": "data for this entity",
"subject": "more data"
}
I didn't do anything different from other peoples' answers. I'll give an update if this problem fails sporadically. But as it is right now, it looks like regardingobjectid may be working in version 9.1
using D365 Api v9.1
POST https://{domain}.crm4.dynamics.com/api/data/v9.1/posts
{
"regardingobjectid_contact#odata.bind":"/contacts(guid)",
"text": "This is a private message post",
"source": 1,
"type": 4
}
source :
Auto Post
Manual Post
ActionHub Post
type :
Check-in
Idea
News
Private Message
Question
Re-Post
Status
I have created a web application from which I am trying to get recommendations of a user from his/her LinkedIn Profile using URL
String url="https://api.linkedin.com/v1/people/~:(recommendations-received:(id,recommendation-type,recommendation-text,recommender))?format=json"
When I am using this URL in the
Api Explorer it works fine. And gives output:-
{ "recommendationsReceived": {
"_total": 2,
"values": [
{
"id": 558598601,
"recommendationText": "xxx is among the best team players I ever worked with. He has handled client effectively with smooth operations. I had always seen him as person with solution mindset and always look for solution rather than thinking about the problem. ",
"recommendationType": {
"code": "colleague"
},
"recommender": {
"firstName": "XXX",
"id": "YYYY",
"lastName": "XXX"
}
},
{
"id": ZZZZ,
"recommendationText": "XXX is one of the most dedicated person at work.I always him with a flexible attitude and ready to adapt himself in all situation.I have seen him work all night to catch up all the deadlines and deliver on time ."
"recommendationType": {
"code": "colleague"
},
"recommender": {
"firstName": "XXX",
"id": "YYYY",
"lastName": "XXXX"
}
}
] } }
The problem comes, when I am using this URL in my Developer app.It doesn't give any error just simple return an empty map [:] as output in response
Irrespective of these recommendation fields, I successfully get the user basic profile data such as email, id, image,firstName,lastName.Means my code is working for other fields well but not for these recommendation fields*
To find the solution, I did some internet surfing and find a link of Linked API docs
Linked API Docs
As per Docs following selection of profile fields are only available
to applications that have applied and been approved for the Apply with
LinkedIn program:
Recommendation Fields
I already created a LinkedIn Developer account to get key & Secret
So how do I apply and get approval for Apply with LinkedIn Recommendation Fields.
I already have seen the LinkedIn support but can't find the way to ask question to the Linked Developer help support
Please suggest me the right way.
After a long internet surfing,I have found something fruitful that, I have to fill up a form to get these fields.Here is the form
along with its procedural details
You can use just recommendations-received keyword. Try the following link. I am getting all recommendations details with this link.
https://api.linkedin.com/v1/people/~:(recommendations-received)?format=json