How can I add a content item from server side (non webapi) code?

Nov 5, 2015 at 3:43 AM
Thanks in advance to anyone who can help with this.

I have a requirement where I have to link a content item (call it Member) with a new dnn user when they register.

I want to use the built in DNN UI for registration, so I've created a custom membership provider and overridden the CreateUser method, but I'm stuck on how to create a new "Member" 2sxc content item, from this method.

I tried creating a class that inherits SxcApiController, but calling it directly won't work, since there is no request object.

I was looking into calling it using an HttpClient instance, but I'm not sure how. Then I thought there must be a way to call the Create method on the server. Something like App.Data.Create(contentType, values) but not within the SxcApiController context.

Once again, thanks to anyone who can offer any insight.