for our scopes we need to use unique ID generated by us for the answers submitted by users. This is possible by adding "?c=" at the end of the survey link followed by the ID number.
Example Format: http://www.surveymonkey.com/s/XXXXX?c=00001
The terrific problem is that the custom value is not returned anyway via API. It is not added as a property of the Answer object neither its value replaces somehow the respondant_id property.
We see that you are able to expose that data from your internal endpoints that you use for your proprietary web interface but how to get this data from he outside via API?
Thanks
When you call 'get_respondent_list', ensure you pass through 'custom_id' in the list of strings in the 'fields' parameter. This will then be returned in the output with the custom value you entered.
Related
We are using KeyCloak as SSO directory for our application. We use OAuth 2.0 protocol.
We have defined one custom attribute in KeyCloak, and this attributed has "MultiValued" properties on.
Then, each user has multiple values entered as value1##value2##value3
For some users Keycloak correctly send the attribute in the ID token as an array of values, such as ["value1", "value2", "value3"]
But for some other users, the string is passed as it is entered "value1##value2##value3", which is not correct.
I'm struggling finding why these different behaviours occur.
Has anyone seen the same problem ?
Thanks a lot
Keycloak uses ## as a delimiter internally, this is ok. Make sure you have marked the value as multivalued in the clients mapper.
After doing this i went from getting only the last element to getting all elements.
I've created an ADF flow that loops over URL's to fetch OData using the OData connection.
However, not all fields are available in all URL's, there are certain ones that are available in one URL, but not in the other. A $Select is used to select the fields that we need.
Is it possible to have an optional selection (as in, if the path is not available, do not fetch this field and return null instead for instance)? Would help us a great deal.
I've tried adding ? after the field, but that does not work. $select=Field1,Field2,FieldOptional?
Thanks
As I understand you are trying to loop through a bunch of a URL and the query on the ODATA URL will change and so will be the fields . I think you can use a lookup where you pass the unique url and its gives the fields and then concatenate the url with the fields and make a odata call .
Using JIRA, I get a list of IDs for worklogs updated by using this api.
/rest/api/2/worklog/updated
I can get the regular request to work, but there is a parameter called expand to display additional properties of the worklog and I can not get these properties to appear.
Things I have tried so far.
/rest/api/2/worklog/updated?expand=spentTime
/rest/api/2/worklog/updated?expand=authorName,comment
The example response in JIRA document (link mentioned above) has a field called properties. It may be used to contain expand properties.
But I don't know why my response doesn't have that field.
If what you're looking for is timeSpent, expanding properties is not the correct approach. You're going to get the relevant workLogIds returned by Get IDs of updated worklogs, then make a second REST call to Get worklogs. This call will give you timeSpent, and updateAuthor among others. However, it will not give you comments; you'll be needing a different call for that.
Based on the information here http://docs.valence.desire2learn.com/res/course.html#actions I would expect that to 'update' a courseOffering I would specify a PUT with a CourseOfferingInfo block, which only contains a few attributes. Every time I try this, I get a 404, not found - even using the same route for a successful GET (404 says org doesn't exist OR org is not an offering - neither is true). However, if I specify a CreateCourseOffering block (directly from a previous GET), the PUT works fine. Is this correct and the documentation not? Or are there other things I should look for in this scenario? The documentation says use CreateCourseOffering for the POST to create an offering… I simply want to update one attribute of that offering and as such thought the PUT was the way to go.
If you use the "create" POST route with a CreateCourseOffering block, this will create a new course offering, and send back the CourseOffering block for the newly created course offering (this will include the org unit ID value for the new org unit you've built).
If you want to update an existing course offering, you should, as you suspected, use the "update" PUT route with a CourseOfferingInfo block. Note that you must provide valid information for all the fields in this block, since when used successfully, the LMS will use all the properties you specify in that block for new values for the org unit. The StartDate and EndDate fields are particularly finicky: you must provide either a valid UTCDateTime value (notice that the three-digit millisecond specifier in these values is mandatory) or a JSON null value if the field is not applicable.
Why a 404? What you're seeing with the 404s and the data you're passing is likely down to the way the back-end service is doing data binding. It tries to de-serialize your provided JSON data (and query parameters) into data objects it can read/manipulate -- if you provide a JSON block that contains a superset of the properties it's expecting, then this may work (for example, if you provide a CourseOffering block when you're expected to provide a CourseOfferingInfo) as the binding layer may ignore fields it doesn't need. If the binding process fails, because you provide a value for a property that can't be bound to the data type expected, or because you fail to provide a JSON property field it expects, then this can cause the service to return a 404 (because binding/de-serializing incoming parameterized data happens at the same time as matching the URL route to an underlying service handler).
If you provide a JSON structure (and query parameters) that the web-service can bind to its expected data objects, but the values you provide are invalid or nonsensical, then this can cause the underlying service handler to respond with a 400 (signalling an Invalid Request). But in order to get this far, your parameterized data still needs to get properly deserialized and bound into data objects for the underlying service to examine.
We'll be updating the documentation to more explicitly draw out this fact. The safest policy from the calling client perspective is to pass valid JSON structures that are exactly what's expected by the individual routes, especially since the underlying back-end service implementation might change how it handles incoming requests.
when we use this API https://app.asana.com/api/1.0/tags, the id and name of the tag is alone exposed... we get this response without colour property
{"data":[{"id":745415432,"name":"niceTag"},{"id":74273131186,"name":"halfBoil"}, {"id":745540236,"name":"DummyTag"}]}
To get the colour property of the tags, we need to individually make a GET request to https://app.asana.com/api/1.0/projects/project-id.
{"data":{"id":123456789,"created_at":"2013-08-15T01:17:32.791Z","modified_at":"2013-08-27T19:14:00.570Z","name":"newPro","notes":"","archived":false,"workspace":{"id":6687953,"name":"t"},"color":"light-yellow","followers":[{"id":987654321,"name":"xxxxx"}]}}
I might be unnecessarily using the server resource for getting colour properties of individual tags. Is there any other way to get the colours?
In most requests for a set of resources, we send what's called the "compact" form - for tags and projects, this includes only the ID and name. However, you can use the opt_fields parameter to request specific fields. For example, if you wanted to get all projects with name and color (ID is always sent), you could use: https://app.asana.com/api/1.0/projects\?opt_fields\=name,color
This works for any fields you need in a collection. For more information on opt_fields and other tricks (like using opt_expand to expand embedded resources) see the documentation on input/output options.