How To Use "Everlive" To Update Content in Cloud Code Function

2 posts, 0 answers
  1. Matthew
    Matthew avatar
    16 posts
    Member since:
    Feb 2011

    Posted 29 Oct 2014 Link to this post

    I need to update Content in the back-end inside a Cloud Code Function. Inside the Cloud Code Function, do I need to create the Everlive object as normal or are there other (preferred) ways of doing it?

    var el = new Everlive('your-api-key-here');
    var data = el.data('Books');
    data.create({ 'Author' : 'Harper Lee' },
        function(data){
            alert(JSON.stringify(data));
        },
        function(error){
            alert(JSON.stringify(error));
        });
  2. Anton Dobrev
    Admin
    Anton Dobrev avatar
    539 posts

    Posted 29 Oct 2014 Link to this post

    Hello Matthew,

    You can use the examples from here and tailor them to access your content types from a cloud function. The syntax is the same as in the Cloud Code for a content type.

    Let me know if you have questions.

    Regards,
    Anton Dobrev
    Telerik
     
    Everlive is now Telerik Backend Services, and is part of the Telerik Platform.
     
Back to Top