How can i publish Page using api? [closed]

As Nuno mentioned, use PublishEngine.Publish and refer the syntax and example Syntax: PublishEngine.Publish( new IdentifiableObject[] { linkedComponent }, engine.PublishingContext.PublishInstruction, new List() { engine.PublishingContext.PublicationTarget }); Do something like this:- private void Publish(IdentifiableObject item, PublicationTarget publicationTarget, bool rollBackOnFailure, bool includeComponentLinks) { IEnumerable<IdentifiableObject> items = new List<IdentifiableObject>() { item }; IEnumerable<PublicationTarget> targets = new List<PublicationTarget>() { publicationTarget }; … Read more