question

charles-zink4125 avatar image
charles-zink4125 asked ·

Parameter [schedule.ranges.from] value is invalid

I am trying to create a custom answering rule and have been encountering the following error:

{      "errorCode": "CMN-101",      "message": "Parameter [schedule.ranges.from] value is invalid",      "errors": [          {              "errorCode": "CMN-101",              "message": "Parameter [schedule.ranges.from] value is invalid",              "parameterName": "schedule.ranges.from"          },          {              "errorCode": "CMN-101",              "message": "Parameter [schedule.ranges.to] value is invalid",              "parameterName": "schedule.ranges.to"          }      ],      "parameterName": "schedule.ranges.from"  }

According to the documentation, the format for ranges is "YYYY-MM-DD hh:mm". Below is the JSON I am POSTing.

{   "type": "Custom",   "name": "Calling Rule 1",   "schedule" : {    "ranges": [     {      "from": "2018-10-25 14:00",      "to": "2018-10-25 14:30"     }    ]   },   "callHandlingAction": "UnconditionalForwarding",   "unconditionalForwarding": {    "phoneNumber": "+1112223333"   }  }

Any ideas what's wrong here? Thanks!
General Topic
1 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

1 Answer

· Write an Answer
anton-nikitin avatar image
anton-nikitin answered ·
I believe the correct format should be YYYY-MM-dd'T'hh:mm:ss.

So in your case it should look like

{   "type": "Custom",   "name": "Calling Rule 1",   "schedule" : {    "ranges": [     {      "from": "2018-10-25T14:00:00",      "to": "2018-10-25T14:30:00"     }    ]   },   "callHandlingAction": "UnconditionalForwarding",   "unconditionalForwarding": {    "phoneNumber": "+1112223333"   }  
}    See https://developer.ringcentral.com/legacy-api-reference/index.html#!#DataTypes.html  
Let us know if it works. We will fix documentation.
1 comment
1 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

You can also try it with a timezone offset like:

* 2018-10-25T14:00:00Z
* 2018-10-25T14:00:00+00:00
0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.