Skip to content

REST API Exports doen not work (dashboard, dataset etc) #28180

Closed

Description

@ziggekatten

Bug description

Any API endpoint for exporting data returns the same error:

"message": "Not a valid rison schema {} is not of type 'array'\n\nFailed validating 'type' in schema:\n {'items': {'type': 'integer'}, 'type': 'array'}\n\nOn instance:\n {}

This happens on 3.1.1, 3.1.2 and 4.0.0 using superset official docker container.

How to reproduce the bug

  1. in your browser, goto swagger/v1
  2. Authenticate with tokens
  3. Klick on any GET endpoint example: api/dataset/export
  4. klick try it out
  5. klick execute

Screenshots/recordings

image

Superset version

3.1.2

Python version

3.10

Node version

16

Browser

Chrome

Additional context

Database used is Postgres 16

LDAP used for authentication (Active Directory)

FEATURE_FLAGS = {"TAGGING_SYSTEM": True, "RLS_IN_SQLLAB": True, "DRILL_TO_DETAIL": True, "ALERT_REPORTS": True, "DASHBOARD_CROSS_FILTERS": True, "DASHBOARD_RBAC": True, "THUMBNAILS" : True, "THUMBNAILS_SQLA_LISTENERS": True, "ENABLE_TEMPLATE_PROCESSING": True, "ENABLE_TEMPLATE_REMOVE_FILTERS": True, "ENABLE_SCHEDULED_EMAIL_REPORTS": True, "EMAIL_NOTIFICATIONS": True,"EMBEDDED_SUPERSET": True}

Checklist

  • I have searched Superset docs and Slack and didn't find a solution to my problem.
  • I have searched the GitHub issue tracker and didn't find a similar bug report.
  • I have checked Superset's logs for errors and if I found a relevant Python stacktrace, I included it here as text in the "additional context" section.

Activity

  1. FiiL123 commented on Sep 17, 2024

    @FiiL123

    This is not working for us either in 4.0.2.
    @michael-s-molina; @rusackas can someone please check.

  2. rusackas commented on Apr 11, 2025

    @rusackas
    Member

    Maybe @dosu-bot can help, but I haven't a chance to try to reproduce this, and it's been silent for quite a while. I assume this is still an issue?

  3. msyavuz commented on Jul 17, 2025

    @msyavuz
    Member

    I can confirm it still exists. In web-app we put a token in the query parameters along with the dashboard id's. This is probably an issue with how swagger is setup for these endpoints

  4. rusackas commented on Mar 11, 2026

    @rusackas
    Member

    Confirmed still present in master per @msyavuz — the issue is related to how the Swagger UI sets up these export endpoints (token in query params). A fix may require updating the Swagger spec or endpoint authorization for the export endpoints. PRs welcome.

  5. rusackas commented on Jul 21, 2026

    @rusackas
    Member

    This isn't the export endpoint being broken, rather it's that get_export_ids_schema has no example, so Swagger UI's "Try it out" defaults q to {} instead of an array like !(1,2,3). Adding an example to the schema would fix the confusion.

  6. Abdulrehman-PIAIC80387 commented on Jul 21, 2026

    @Abdulrehman-PIAIC80387
    Contributor

    Thanks @rusackas — picking this up. Adding "example": [1, 2, 3] to all 6 get_export_ids_schema dicts (dashboards, charts, datasets, databases, saved_queries, themes) so Swagger UI's "Try it out" pre-fills a valid array. PR incoming.

  7. rusackas commented on Jul 22, 2026

    @rusackas
    Member

    Thanks for picking this up @Abdulrehman-PIAIC80387, #42265 adds examples to the six get_export_ids_schema schemas so Swagger's Try it out pre-fills a valid array instead of {}. That should close this out once it lands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions