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

Draft deploy #2

Open
TechWatching opened this issue Mar 8, 2019 · 2 comments
Open

Draft deploy #2

TechWatching opened this issue Mar 8, 2019 · 2 comments

Comments

@TechWatching
Copy link

Is there a way to use the UpdateSite method but specifying that this is a draft deploy to avoid publishing directly the new deploy to the site ?

I am a bit confuse as the Netlify Open API does not specify the route used by the UpdateSite method. However this route is mentionned on the Netlify documentation. I know that this is possible when using file diggest but it is not implemented in NetlifySharp. Are there plans to update the NetlifySharp library ? Is implementing the whole Netlify API still a goal ?

@daveaglick
Copy link
Owner

Is there a way to use the UpdateSite method but specifying that this is a draft deploy

As far as I know, the implemented endpoints support all the available options. Though it's been a little while since I worked on them, so it's possible Netlify has added more properties since then. I'm not sure if the UpdateSite endpoint accepts a "draft" flag (or what that would do - does Netlify have the concept of "drafts"?)

Are there plans to update the NetlifySharp library? Is implementing the whole Netlify API still a goal?

Yes - I plan to eventually add missing endpoints and am happy to take a look at expending the endpoints that have already been implemented if there are new properties. I'd love to get support for things like forms implemented - just a matter of finding the time.

@TechWatching
Copy link
Author

Yes Netlify has the concept of draft:

When creating a new deploy, you can set "draft": true to mark the deploy as a draft deploy.
Draft deploys works just like normal deploys, but they won’t change the active deploy of the site once they’re done processing.

But from what I understand the draft flag should be set in the body of POST request to /api/v1/sites/:site_id/deploys which is not the endpoint the UpdateSite uses.

I will play a little with the Netlify API when I will have some time, to see if the draft flag can easily be added to NetlifySharp. What is deconcerting is that Netlify documentation and their swagger don't have the same information.

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

2 participants