How to add "Access Filter" to data source using REST API

Jesse Kahtava shared this question 21 days ago
Completed

Hello
I am trying to fully automate the creation of a new client org.
So far I have all the steps working for creating the new client org; adding users; creating a data source; enabling client data source in parent org (POST api/data-sources/$parent_data_source_id/client-data-sources?clientSourceId=$source_id).

The final step that is to configure the "Access Filters" for the client data source.

I can successfully do this from the UI, but I don't see any references to it in the REST API documentation. Is there an endpoint that hasn't been documented?

I noticed that even after configuring the access filters a GET for the data source doesn't return anything relevant in the JSON response. https://developers.yellowfinbi.com/dev/api-docs/current/#operation/getDataSource

6534d39e00f6fa8cba80b52bebd5a085

Replies (3)

photo
1

Hello Jesse Kahtava,


My name is Siddartha Pathi from the Yellowfin Technical Support Team. We have received your support request, and I will be your primary contact on the following ticket:

Ticket Number: #{32022}
Case Title: {How to add "Access Filter" to data source using REST API}

According to the REST API documentation, we have the ability to refresh the source filter (access filter) for the Data Source. You can find more information here:

https://developers.yellowfinbi.com/dev/api-docs/current/#operation/refreshDataSourceFiltersRPC


Please let me know if this helps or if you have any further questions.


Sincerely,

Siddartha Pathi

Yellowfin Technical Support Engineer

photo
1

Thank you Siddartha.I don't want to refresh the source filter.


I want to create/modify the Access Filter (is that the same as a source filter?).

photo
photo
1

Hello Jesse Kahtava,

Greetings of the day

Thank you for your response. I have verified that currently, there are no REST APIs available to directly create access filters. The only method to achieve this is by importing a data source that has an attached SQL access filter.

If you have any additional questions or need further assistance, please don't hesitate to reach out to us.

Sincerely,

Siddartha Pathi

Yellowfin Technical Support Engineer

photo
1

You mentioned "importing a data source that has an attached SQL access filter".

How is this accomplished? Is there a REST API for this process?

photo
1

Hello Jesse Kahtava,

Greetings of the day

Thank you for the response. You may utilize the POST /api/rpc/import-export/import-content endpoint. If your export file is prepared with the required SQL access filter, you can upload it through the import endpoint. For this purpose, you can refer to the import-export endpoints in Yellowfin ReDoc.

https://developers.yellowfinbi.com/dev/api-docs/current/#tag/import-export

Sincerely,

Siddartha Pathi

Yellowfin Technical Support Engineer

photo
1

How can I achieve "importing a data source"? Right now I am creating new ones using the Rest API.


How does importing work? Do I create a template of some kind? Is there a Rest endpoint for this?

I'm trying to figure out if I can do this process instead of using the /api/orgs POST: https://developers.yellowfinbi.com/dev/api-docs/current/#operation/createOrg

photo
1

Hello Jesse Kahtava,

Greetings of the day

Thank you for the response. To import a data source in Yellowfin using the REST API, you need to use the POST /api/rpc/import-export/import-content endpoint. This process involves creating a template in the form of a YFX/XML file that contains the data source configuration you want to import. The import process allows you to inject replacement values for database connection details such as the host, database name, user, and password.

Prepare a YFX/XML file that contains the data source configuration. This file should include placeholders for values that need to be replaced, such as [SERVER_ADDRESS], [DATABASE_NAME], [USER_NAME], and [ENCRYPTED_PASSWORD].

Define the import options in JSON format. These options specify how the import should be processed. For example, you can specify whether to skip existing items or add new ones.

Use the POST /api/rpc/import-export/import-content endpoint to import the data source. This involves sending a multipart form request with two parts: contentToProcess containing the YFX/XML content and importOptions containing the import options.

Please let me know if this helps or if you have any further questions.


Sincerely,

Siddartha Pathi

Yellowfin Technical Support Engineer


photo
1

Thank you! I will explore this option. It appears to be what I am looking for.

photo
1

Hello Jesse Kahtava,

Greetings of the day

Thank you for your prompt response. Kindly inform me if we can proceed to close this ticket or if there is any additional information you require regarding this matter.

Sincerely,

Siddartha Pathi

Yellowfin Technical Support Engineer

photo
1

Hello Jesse Kahtava,

Greetings of the day

I just wanted to check in to see if you had a chance to review the response below. Please let us know when you can.

Sincerely,

Siddartha Pathi

Yellowfin Technical Support Engineer

photo
1

Hello Jesse Kahtava,

Greetings of the day

I just wanted to check in to see if you had a chance to review the response below. Please let us know when you can.

If you are unavailable right now, you can always contact us again at a later time by opening a new ticket I will close this case by the end of business tomorrow if I do not receive a reply.

Please let us know if you need additional support on this issue.

Thank you,

Siddartha Pathi

Yellowfin Technical Support

photo
1

Hello Jesse Kahtava,

Greetings of the day

Just wanted to let you know I'll be closing this request due to inactivity. However, if you ever want to revisit this or have anything else I can help you with, please let me know.

Thank you,

Siddartha Pathi

Yellowfin Technical Suppor

photo
photo
1

Hello Jesse Kahtava,

I just wanted to check in to see if you had a chance to review the response below. Please let us know when you can. Thanks!

Sincerely,

Siddartha Pathi

Yellowfin Technical Support Engineer

Leave a Comment
 
Attach a file