Is that possible to create projections with .Net API?

I was doing some R & D work, I just wanted to know whether I could use the .Net API to create any projection in the event store?

Thank you


It depends on exactly what you mean:

  • you can control projections/post new ones etc over a restful API that can obviously be consumed through .NET

  • there is currently no way to host projections inside the event store written in any .NET languages, HOWEVER projections doesn’t do anything internally you can’t do externally of necessary (operations like linkTo just write events structured in a certain
    way). This is probably how you’d do read models in a CQRS-type pattern.

Hope that clears it up,


Thanks James, for quick and prompt reply.

One more quick question, Is that possible to set access control of users for a projection?

(may be not through the API, just wanted to make sure its possible thing to do)


When you say access control do you mean access control to edit it or access control that it should run as? Both of these are possible. To set the control for editing etc a projection is stored in a stream and can be controlled as normal. Aside from that queries/projections run with the permissions of who they were created with

Thanks Greg


Does anyone know whether there are any plans to make it possible to write projections in .NET?. Judging from the code it would seem that most of the bits and pieces are there already. While there are certainly a number of valid reasons for supporting javascript I
can’t help but feel that even with the fairly basic projections I have written so far, it would have been a lot easier and cleaner if I could just upload a .NET DLL and point the store to the types it should use.


There is also a problem that a projection in .net could down the db

Everything projections does you can do via the client API (links etc are just normal events with magic event types starting with $), but we don’t internally support .NET projections.

What if your clients were all http or akka and didn’t have .net types associated with them?

Yeah, but if I did it through the current client API I would have to implement checkpointing, a host for the projections and error handling and all that stuff myself. The fact that Eventstore deals with all that stuff for me is in my view its biggest strength. But I guess one could make a generic ‘external projection host’ that could do most of that stuff for you and provide an API better suited for writing projections.

It’s only better suited if you’re coming from .NET in the first place :slight_smile: