Recent searches


No recent searches

Trying to update custom app via API fails with 'The task failed because of an error: no implicit conversion of nil into String'



Posted Mar 23, 2022

Here are the steps I tried:

Uploaded a file using POST https://d3v-brastel.zendesk.com/api/v2/apps/uploads.json

Got response with upload_id:

reponse_body: { id: 1840900 }

Started update of app passing the received upload_id:

PUT api/v2/apps/788738 body={"name":"Basix","short_description":"Basix","upload_id":1840900}

Waiting for app update job to complete

Checking app update job status
GET api/v2/apps/job_statuses/81ca43f4c621440f85ae0ff99a2c86f7 body=null
{ id: '81ca43f4c621440f85ae0ff99a2c86f7',
  url: 'https://d3v-brastel.zendesk.com/api/v2/apps/job_statuses/81ca43f4c621440f85ae0ff99a2c86f7.json',
  total: null,
  progress: null,
  status: 'failed',
  message: 'The task failed because of an error: no implicit conversion of nil into String',
  retry_in: 3 }


0

2

2 comments

Sorry,

when uploading the file data, I used form parameter "file" instead of "uploaded_data" (as require by the API).
After correcting this, it worked:

zendesk_request PUT api/v2/apps/788738 body={"name":"Basix","short_description":"Basix","upload_id":1840932}
Waiting for app update job to complete
Checking app update job status
zendesk_request GET api/v2/apps/job_statuses/de6a9ed7968eb547ab69faa540a453ce body=null
{ id: 'de6a9ed7968eb547ab69faa540a453ce',
  url: 'https://d3v-brastel.zendesk.com/api/v2/apps/job_statuses/de6a9ed7968eb547ab69faa540a453ce.json',
  total: 105,
  progress: 105,
  status: 'completed',
  message: 'Basix updated.',
  retry_in: 3,
  app_url: 'https://d3v-brastel.zendesk.com/api/v2/apps/788738.json',
  app_id: 788738,
  app_name: 'Basix' }


So everything is OK.

Thanks.

 

0


image avatar

Tipene Hughes

Zendesk Developer Advocacy

Hi Mayama,
 
Glad to hear everything is working now.
 
Have a great day!
 
Tipene

0


Please sign in to leave a comment.

Didn't find what you're looking for?

New post