Closed sagrawal31 closed 4 years ago
Hi there Shashank. I believe that you are trying to set the custom data field by using these:
extras.put("questionID", "5e428e8de7b8f5690b9db8f5");
extras.put("candidateID", "5e42882ae7b8f5690b9db7ee");
The custom data section is actually a single parameter that you can fill in with your own custom data that has to be a valid JSON format to be accepted.
So instead of setting 2 parameters, you would actually be setting one with a code that would look something like so:
HashMap<String, String> extras = new HashMap<>();
extraArguments.put("data","{\"questionID\":\"5e428e8de7b8f5690b9db8f5\",\"candidateID\":\"5e42882ae7b8f5690b9db7ee\"}");
ziggeo = new Ziggeo(APP_TOKEN, CameraFullscreenRecorderActivity.this);
RecorderConfig config = new RecorderConfig.Builder()
.callback(prepareCallback())
.sendImmediately(false)
.enableCoverShot(false)
.maxDuration(50000)
.extraArgs(extras)
//.facing(CameraView.FACING_FRONT)
.build();
ziggeo.setRecorderConfig(config);
ziggeo.startCameraRecorder();
Now I do want to mention that I am not really Android dev, so the JSON part can be done in any way that makes sense, or you prefer. The only requirement is that it is a valid JSON string that is passed. :)
Of course, do let us know how it goes. :)
Hi Shashank :)
Bane is right, to put a custom data you need to use data
key in extra args.
Oh! Thanks @Bane-D & @3akat
I got your point about the way to pass the JSON data in a custom field data
. I'll manage to format the string and pass that but I got another question, why a map extraField
is being used when we have to pass a single string? What else can we pass to .extraArgs()
Map?
This is working now:
We can close this issue but before that can you please answer my above question?
why a map
extraField
is being used when we have to pass a single string? What else can we pass to.extraArgs()
Map?
Never mind!
I managed to figure out why a map is being passed there. That is for setting title
, description
, tags
etc. as I saw it here (this is from where I figured out 😄 )
yup, you've found a right info :) Actually there is somewhere a list of params we can use as extra args, but I wasn't able to find it fast, so let's wait for @Bane-D to help with the info :)
Thank you @3akat that will help.
My suggestion is to update this info (which @Bane-D will provide) in the Android SDK docs at https://ziggeo.com/docs/sdks/mobile/android
I see that it's there but I think that is not sufficient.
Hi there Shashank.
The idea was to make our mobile SDKs follow with the same options as our JS SDK offers. You can see all of them here: https://ziggeo.com/docs/sdks/javascript/browser-integration/parameters
Now since this is mobile SDK some things had to be crafted a bit differently, so they are offered in their own methods. There were also some things that had to be named differently.
So in general if you see a parameter on the above page that you would like to use, you can try to use it in the Android and iOS SDK. If they are not supported by some chance let us know.
Again some parameters would just not make sense for mobile SDKs and would not be supported.
Just of top of my head our customers would usually use the following:
data
(custom-data
in JS SDK)effect_profile
(effect-profile
in JS SDK)video_profile
(video-profile
in JS SDK)tags
client_auth
server_auth
expiration_days
Hope this helps :)
Also thank you for your suggestion on the docs page. We are constantly improving them and plan to add more examples in there. Having a list of all supported parameters would also be interesting to do, so thank you again and enjoy your codding :)
Hi @Bane-D
The idea was to make our mobile SDKs follow with the same options as our JS SDK offers.
I believe & agree with that.
Thank you for the clarification. Like I mentioned above, I managed to figure out a few out of them.
I'm setting some string-based data in the Ziggeo recorder:
But it's not reflecting in the dashboard once the videos are processed:
Am I missing something?