Using Ektron 8.02, I'm trying to retrieve the Post Back Message of an Html Form using only the API. I haven't been able to find a property on the Ektron.Cms.FormData object which provides this, nor any method in the `Ektron.Cms.API.Content.Form' class which will retrieve it. Is what I'm trying to do even possible through the API or should I instead attempt to get this from the database directly?
I've found it. To get all of the data from an Html Form you'll need to get the form as FormData and ContentData objects. Inside the ContentData.Teaser property is a bit of XML that contains the postback message among other things. Will have more information after I get back to my work machine.
Related
My company is using a CKAN instance configured with Data Store and DataPusher. When a CSV file is uploaded to CKAN, DataPusher sends it to the DataStore and creates a default Data Dictionary for the resource. The Data Dictionary is a very nice feature to display the description of data fields for the users. Here is an example (it is in Brazilian Portuguese):
I can update the Data Dictionary using the UI, or it can be sent as part of the Fields passed to datastore_create().
My problem, is that I don't control the call of datastore_create() because this method is automatically called buy the DataPusher service.
I want to programmatically set the values of the Data Dictionary, but I can't find the api call that allows me to do it. An api call that update the Fields metadata. Can I do it using the Api? Or maybe it is possible create it when I create the data resource. I'd like a code example.
You can use the API call datastore_create on top of an existing table. This will not impact the data in the table.
You should use the datastore_search to check the format of how the dictionary is saved in one of your resources (result->fields->info). Use that as your base, make the desired changes, and use it in the body of the datastore_create call.
Unfortunately, the API call datastore_info does not give you back that information.
The majority of the CKAN UI functionalities can be made through the API as well. In this case, you can make use of the "datastore_create" by the controller --> See Code here.
Using react-admin, I have build an ExpressJS API including a GraphQL endpoint. All my resources in react-admin are using the graphql data provider. For a specific resource, I'm looking to fetch some configuration from my API endpoint to generate the form based on the context. I will try to create a mock example as I can't use the actual application's lingo.
For example, if I edit resource Post, and I assign a specific type "Photo", then I want some specific metadata to be saved in the form. My issue is the specific metadata object is coming from the API configuration for type "Photo". So if I select type "Photo", I want to save "Capture Date", "Camera Make", "Camera Model", etc.
The backend configuration would probably be in the form of a JSON schema describing the fields, the label, the key and the type of input (text or password).
TLDR: I want to fetch a configuration in the API and use it in the app to generate a list of form inputs. How can I do this without registering the call as a resource, since I don't feel like it is?
Edit
I haven't tried anything yet as I was asking a theoretical question to see if anybody had a "proper way" to suggest. My two options were the following:
Create a Resource for the PostType and it would simply return the list of fields as a JSONschema when called with GET_ONE. This would make use of the dataProvider to do the fetching.
Simply use fetch in my form and call my API endpoint directly.
Is there a specific request format that the webhooks have? I am using the Pull Request Updated event, and I am trying to deserialize into a class, but I do not know what fields I will need. Is there a class or example of the request content details for the different events?
As far as I know, there isn't a generic template for the HTTP post request/response from TFS.
The TFS HTTP post JSON request/response format is based on the specific action.
For example, for the web hooks whenever a work item is updated.If I update a description field, I am getting one format and if I add a child work item, I am getting another format.
However for the specific event, you can check the response format, then get the useful information which you needed.
Please refer to Send JSON representation to a service for more information.
And at the end of the Q&A part there is a sample JSON.
For a project I'm working on, I need to access Custom Form data via the AtTask REST API. Specifically, I need to surface the text associated with any checked checkboxes within a custom form.
To see where this data might be visible, I've done a query of the form:
https://<company>.attasksandbox.com/attask/api/v4.0/task/search?method=get&sessionID=xxxxxxxx&fields=parameterValues
...but I'm not seeing the checkbox data I'm looking for.
Is it possible to surface this kind of data via the API?
If so, what's the proper syntax?
The parameterValues fields will return all the custom data that is set on the task. You can request the specific parameter by calling it by name like DE:Parameter Name. Both will only return the selected values of the checkbox. If you would like all values for the field then you will need to pull them from the parameter and parameter options objects.
https://<company>.attask-ondemand.com/attask/api/v4.0/popt/metadata
The API specifies that when requesting a login form for a financial website, it would return a JSON Form object, but never specifies the nature of this object. API documentation on this topic here.
I need to write a parser so that I can insert the form as html into my page. Is there anywhere where I can find a parser, or at least see some documentation on this JSON Form object?
The article you linked shows the object that returns. You need to build the form based on that. For example when typeName is TEXT, you need to display a and when it's IF_PASSWORD you create a field of .