Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add DeletedAt to APIObject #509

Open
mattbnz opened this issue Jan 10, 2024 · 0 comments
Open

Add DeletedAt to APIObject #509

mattbnz opened this issue Jan 10, 2024 · 0 comments

Comments

@mattbnz
Copy link

mattbnz commented Jan 10, 2024

Some PagerDuty API responses appear to return an undocumented deleted_at key in their APIObject encodings when including objects that are no longer in-use. Can this field be added to APIObject so callers can make use of it to filter the returned lists?

It looks like a simple/straightforward change, but given the deleted_at field is undocumented as far as I can tell, I'm hesitant to rely on it or send a patch without some confirmation first.

More Details:
I'm seeing this primarily on the ListSchedules API call, where the returned list of users can include entries for (apparently deleted) users whose IDs are no longer included in corresponding ListUsers calls. Currently in the API response there is no indication or way to tell which of the returned users are valid API objects that can be used in further API calls and which will result in errors...

However, in the underlying JSON there is an (undocumented) deleted_at key that would be very useful to expose to golang callers to allow filtering of the returned list of users - however because DeletedAt is not present in the APIObject struct this information is currently lost and unusable by consumers of the golang API.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant