Restores a deleted draft post from the trash bin by the provided ID.
Uses the draftPostId
to restore a deleted draft post from the trash bin.
function restoreFromTrashBin(
draftPostId: string,
): Promise<RestoreFromTrashBinResponse>;
Draft post ID.
import { draftPosts } from "@wix/blog";
async function restoreFromTrashBin(draftPostId) {
const response = await draftPosts.restoreFromTrashBin(draftPostId);
}
This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.