Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Downloadable items query #871

Closed
alexookah opened this issue Jun 25, 2024 · 2 comments
Closed

Downloadable items query #871

alexookah opened this issue Jun 25, 2024 · 2 comments

Comments

@alexookah
Copy link

I'm currently working on implementing a page similar to WordPress Downloads, where users can view their downloadable purchases.

To achieve this, I'm querying the orders and then filtering them client-side to display only the downloadable items. Is there a way to define a where field in the query to directly retrieve orders that include downloadable results?

Thank you!

@alexookah
Copy link
Author

Eventuall I used this query to get my downloads:

query getDownloads {
    customer {
        downloadableItems {
            nodes {
                url
                accessExpires
                downloadId
                downloadsRemaining
                name
                product {
                    databaseId
                }
                download {
                    downloadId
                }
            }
        }
    }
}

@alexookah
Copy link
Author

Closing this issue since i do not need to query anymore for orders with downloadable content. getting user downloads worked for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant