Skip to content
TORNLIFE More

[API] Inconsistent behavior with non-numeric IDs

Started by Patient [2131539] on in Bugs & Issues.

3 replies · 113 views · thread synced · 4 days ago · View on torn.com
About this thread

Posts archived: 4 / 4 posts (100%) · the total is Torn's reply count + the opening post at the last fetch

Counted by TornLife from the archived posts.

Archived posts
4
Discussion span
→
People posting
4
Likes on archived posts
0
Posts by staff, officers and moderators
3
Authority score
58 / 100
Historical score
48 / 100
Story score
42 / 100
Engagement score
41 / 100
Patient [2131539]
If an incorrect numeric ID is requested via API, there is either an error code of 6, or values are returned as null:

[image: i.imgur.com]

[image: i.imgur.com]

However if anything other than a number is entered into the ID section of the URL, the results default to returning values as though no ID was entered at all:

[image: i.imgur.com]
[image: i.imgur.com]

Shouldn't invalid non-numeric ID's return the error code of 6 like they do when with invalid numeric ID's?
Chedburn [1] Admin Developer
I'd need to check with Pavel. Ideally all categories would act consistently, the same way, with the same error responses.
splent [2088243] Admin Staff

Hey,

 

Thanks for the report. 

 

These are now fixed in API v2 so I'm marking this bug report as fixed.

 

There will be no API v1 changes made to this behaviour. 

 

Thanks!