Comments (8)
This error message is as specific as you'll get. You want to look over the json object you're sending to make sure it is both - valid json & valid entities (spelling, etc...). Do you have an example of the json object you're passing when creating the ticket?
from zendesk_api_client_php.
@mtymek I should mention that the conversion to JSON is taken care of, so you'll want to share the structure of the multi-dimensional array you're passing to the create method.
from zendesk_api_client_php.
I can't give you exact data that causes this problem - it happens from time to time, with no clear indication why.
We have a form where customer can submit a ticket. Submission looks like this:
$client->tickets()->create(
array(
'subject' => $form->getValue('subject'),
'tags' => [$form->getValue('about')],
'requester' => [
'email' => $form->getValue('email'),
],
'comment' => array(
'body' => $description
),
'priority' => 'normal'
)
);
Looks like filters & validators in my form are too open and can let through something invalid. However, without a clear message like "subject contains invalid characters", I cannot understand why it's happening.
from zendesk_api_client_php.
Any chance to get some information on this topic? It seems to be random, for example today it's not working for certain e-mail addresses while it works for others
Doesn't work:
Array
(
[subject] => [Something] test
[tags] => Array
(
[0] => Payment-Live
)
[requester] => Array
(
[email] => [email protected]
)
[comment] => Array
(
[body] => Request about: Payment-Live
test test test
offerID: E366996532_FR
event url: http://dev-test1.cleeng.com/test-new-event/E366996532_FR
BROWSER PARAMETERS:
HTTP_USER_AGENT:Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062.120 Safari/537.36
IP: 127.0.0.1
)
[priority] => normal
)
Works:
Array
(
[subject] => [Something] test
[tags] => Array
(
[0] => Payment-Live
)
[requester] => Array
(
[email] => [email protected]
)
[comment] => Array
(
[body] => Request about: Payment-Live
test test test
offerID: E366996532_FR
event url: http://dev-test1.cleeng.com/test-new-event/E366996532_FR
BROWSER PARAMETERS:
HTTP_USER_AGENT:Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062.120 Safari/537.36
IP: 127.0.0.1
)
[priority] => normal
)
from zendesk_api_client_php.
ping @dpawluk
from zendesk_api_client_php.
@mtymek I'd suggest you send in a ticket to Zendesk support if you continue having issues finding out why your tickets are not being created. Please include the date/time of the failed ticket creation, as well as the payload.
from zendesk_api_client_php.
I have this problem because I add the parameters in wrong sequence. See my code that works fine :D
https://gist.github.com/fhferreira/a926529dfca3d7eb207e
from zendesk_api_client_php.
@fhferreira @mtymek are you both still having intermittent issues when using the same code?
from zendesk_api_client_php.
Related Issues (20)
- PHP8 Error: array_merge() does not accept unknown named parameters HOT 1
- php 5.6 Parse error: syntax error, unexpected '?', expecting variable (T_VARIABLE) in /var/www/clients/client1/web6/web/vendor/guzzlehttp/guzzle/src/HandlerStack.php on line 47 HOT 1
- Update Packagist with the new version HOT 3
- Unmerged PRs HOT 3
- Okta HOT 2
- Oktane22
- Add comment to ticket HOT 3
- FindAll method Ambiguity in Error Webhooks HOT 3
- No events API support? HOT 2
- Type error: Argument 1 passed to GuzzleHttp\Client::send()
- Allow any PSR-17 and PSR-18 implementation to be used
- How to get the latest tickets created by a customer? HOT 2
- webhook count support not available ? HOT 1
- Repository maintenance status HOT 14
- Problem with updates of users HOT 2
- tickets createMany method implementation HOT 2
- No method called iterator available in Zendesk\API\Resources\Core\Tickets HOT 2
- Testing Slack notification HOT 3
- Test Issue HOT 3
- Another test HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from zendesk_api_client_php.