ASP.NET Web API: enum or strings

apiasp.net-mvc-web-apibackward compatibilityenum

I have an ASP.NET Web API application. It uses enums for some fixed sets of states or types. Now I need to extend enum to support more values. But it will break backwards compatibility so I need to create new version of method. Is it better to use strings for this purpose? I suppose I can easily extend a list of possible string values and this changes don't require new version of api method. What do you think?
UPDATE: I have enum

public enum ElementTypes
{
    Tree,
    Test,
    Post
}

and I need to add two new items into this enum.

Best Answer

Its best to use enums serialised as strings and use versioning to deal with backwards compatibility issues.

This gives you the type safety of enums in your c# code, but retains the meaningful values in your json and consuming apps.

Maybe add more info about your particular backwards compatibility issue? Adding more values to an enum should not necessarily cause a problem. But obviously using strings as input does not solve all possible backwards compatibility issues, so you need versioning in any case