ReportSubscriptionsApi not parsing the response retrieved from the API
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 42/100
Research direction
Start with ReportSubscriptionsApi and ReportingV3ReportSubscriptionsGet200Response, then compare the API response's _embedded.Subscriptions property with the model's Gson mapping. Reproduce the report-subscriptions request and verify that the returned object contains the subscription data rather than null.
Written by the indexing model from the issue text.
Description
Hi,
I'm actually working using the cybersource rest client java and I'm working with ReportSubscriptionsApi to retrieve the Report subscriptions.
Right now I'm facing up with an issue that happens when I'm calling the rest endpoint in order to get that info. The object which should have the reports information is coming as null. I've been debugging directly the response and it is successful and as well, it matches with the response given on the documentation page using my API key and secret.
Digging into the code and doing some research, I'm looking that it may be for the GSON anotation inside that class and the response given by the webservice, seems that there is a mismatch between them.
Please check it up the info below, as you can see the object is coming as Subscriptions
"_embedded": {
"Subscriptions": [
{
"_links": {
"self": {
"href": "https://apitest.cybersource.com/reporting/v3/report-subscriptions/..."
}
},
And, this is on your code, inside the ReportingV3ReportSubscriptionsGet200Response class.
public class ReportingV3ReportSubscriptionsGet200Response {
@SerializedName("subscriptions")
private List<ReportingV3ReportSubscriptionsGet200ResponseSubscriptions> subscriptions = null;
At a glance, it seems that you're waiting for a property called "subscriptions" instead of "Subscriptions". Hence, seems that this would be a potential reason why I'm getting the report info inside of the object as null even when the call to the webservice is successful and the response is coming with data that would be parsed without issues.
Can you please reproduce and confirm if this is an issue?
Kind regards!
- Dominant language
- Java
- Stars
- 29
- Forks
- 50
- Avg merge
- 28m
- Merged PRs (30d)
- 1
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from CyberSource/cybersource-rest-client-java
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
CyberSource/cybersource-rest-client-java#241 · 1 reaction ·
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 58/100
-
Difficulty 3/5 1-2 days Newbie friendliness 42/100
CyberSource/cybersource-rest-client-java#235 · 1 comment ·
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
All issues in CyberSource/cybersource-rest-client-java
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
infinispan/infinispan#18150 ·
-
area/frontend
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
untriaged
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
opensearch-project/k-NN#3597 ·
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 88/100