{"id":18320897,"url":"https://github.com/bazaarvoice/bv-android-sdk-conversations-example","last_synced_at":"2025-04-09T14:29:48.675Z","repository":{"id":66754568,"uuid":"99599280","full_name":"bazaarvoice/bv-android-sdk-conversations-example","owner":"bazaarvoice","description":null,"archived":false,"fork":false,"pushed_at":"2019-07-22T20:17:55.000Z","size":353,"stargazers_count":0,"open_issues_count":1,"forks_count":1,"subscribers_count":11,"default_branch":"master","last_synced_at":"2025-02-15T08:30:58.237Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bazaarvoice.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-08-07T16:44:54.000Z","updated_at":"2019-07-22T20:17:57.000Z","dependencies_parsed_at":"2023-02-22T19:16:06.774Z","dependency_job_id":null,"html_url":"https://github.com/bazaarvoice/bv-android-sdk-conversations-example","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bazaarvoice%2Fbv-android-sdk-conversations-example","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bazaarvoice%2Fbv-android-sdk-conversations-example/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bazaarvoice%2Fbv-android-sdk-conversations-example/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bazaarvoice%2Fbv-android-sdk-conversations-example/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bazaarvoice","download_url":"https://codeload.github.com/bazaarvoice/bv-android-sdk-conversations-example/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248054969,"owners_count":21040100,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-05T18:17:47.193Z","updated_at":"2025-04-09T14:29:48.650Z","avatar_url":"https://github.com/bazaarvoice.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Conversations Example App\n\nFollow the [Installation Instructions](https://bazaarvoice.github.io/bv-android-sdk/installation.html#configure-bvsdk)\nto generate your bvsdk_config_staging.json and bvsdk_config_prod.json files and add them to the \n```app/src/main/assets/``` directory.\n\nYou will need to add in a valid product id, and author id in the \n```app/src/main/com/example/conversations/Constants.java``` file. \n\nIf you launch ```MainActivity.java``` then you should see 2 buttons. One to Display Reviews, and one \nto Submit a Review.\n\n\u003cimage src=\"./art/home.png\" width=\"300\" align=\"middle\"\u003e\n\n## Display Reviews\n\nIn the ```DisplayReviewsActivity.java``` a call is being made to display reviews.\n\n\u003cimage src=\"./art/display_reviews.png\" width=\"300\" align=\"middle\"\u003e\n\n## Submit Review\n\nIn the ```SubmitReviewsActivity.java``` a call is being made to submit a review.\n\nYou may see some form errors if your request does not include all of the field \nrequired per your configuration...\n\n\u003cimage src=\"./art/some_form_errors.png\" width=\"300\" align=\"middle\"\u003e\n\nOnce you go back and edit the Request with the required params, you should now be \nable to submit successfully...\n\n\u003cimage src=\"./art/submit_success.png\" width=\"300\" align=\"middle\"\u003e\n\n## Common Errors\n\n### Submitting with ```Action.Preview``` instead of ```Action.Submit```\n\nWhen you intend for submission requests to actually exist on your backend, you must ensure \n that you are submitting with ```Action.Submit```.\n\nSubmitting with ```Action.Preview``` is useful when you do not want to be spamming your \nenvironment with fake data, or if you simply want to see a submission form from the \n```response.getFormData()``` call.\n\n### Not catching the errors in the ```BVCallback#onSuccess(response)``` method. \n\nA review will only be considered successful when ```response.getHasErrors()``` returns false. \n\nAll ```FormError```, and BV API ```Error``` objects are routed to the \n```BVCallback#onSuccess(ResponseType response)``` method for your callback. \n\nYou should check \n```response.getHasErrors()``` to see if it has either type of error, which you can get \nfrom calling ```response.getFormErrors()``` and ```response.getErrors()```. \n\nThe ```BVCallback#onFailure(BazaarException exception)``` method is only called when an a \nnon-API related error happens, such as no-network, etc.\n\n## FAQ\n\n### Badges\n\n```java\nif (response.getHasErrors()) { \n  // handle it\n  return;\n}\nfinal List\u003cReview\u003e reviews = response.getResults();\nfinal Review review = reviews.get(position);\nfinal Map\u003cString, Badge\u003e badgeMap = review.getBadges();\nfor (Map.Entry\u003cString, Badge\u003e badgeEntry : badgeMap.entrySet()) {\n  final Badge badge = badgeEntry.getValue();\n  final String badgeId = badge.getId();\n  final String contentType = badge.getContentType();\n}\n```\n\n## More info\n\n* [Github repo](https://github.com/bazaarvoice/bv-android-sdk)\n* [Docs](https://bazaarvoice.github.io/bv-android-sdk/index.html)\n* [Generate config files](https://bazaarvoice.github.io/bv-android-sdk/installation.html#configure-bvsdk)\n* [More comprehensive demos](https://bazaarvoice.github.io/bv-android-sdk/example_projects.html)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbazaarvoice%2Fbv-android-sdk-conversations-example","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbazaarvoice%2Fbv-android-sdk-conversations-example","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbazaarvoice%2Fbv-android-sdk-conversations-example/lists"}