Skip to content

Replace successful.ok with json #211

@isaacabraham

Description

@isaacabraham

If you go to the Saturn endpoint directly with a browser that doesn't specify the content type as JSON, Giraffe falls back to using the XML serializer by default. This requires [<AllowCLIMutable>] attributes on all types, and without this you get a confusing error saying that your types requires a non-default constructor or something. This is very confusing for a beginner.

To work around this, we can either explain this in the docs (a good thing to do anyway), but it might also be worth replacing Successful.OK with json in Saturn / Giraffe.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions