File tree Expand file tree Collapse file tree 3 files changed +9
-0
lines changed Expand file tree Collapse file tree 3 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -24,6 +24,7 @@ public static class BlocksApiUrls
2424 public static class PagesApiUrls
2525 {
2626 public static string Create ( ) => $ "/v1/pages";
27+ public static string Retrieve ( string pageId ) => $ "/v1/pages/{ pageId } ";
2728 public static string UpdateProperties ( string pageId ) => $ "/v1/pages/{ pageId } ";
2829 }
2930 }
Original file line number Diff line number Diff line change @@ -6,6 +6,8 @@ namespace Notion.Client
66 public interface IPagesClient
77 {
88 Task < RetrievedPage > CreateAsync ( CreatedPage page ) ;
9+ Task < RetrievedPage > RetrieveAsync ( string pageId ) ;
10+
911 Task < RetrievedPage > UpdatePropertiesAsync (
1012 string pageId ,
1113 IDictionary < string , PropertyValue > updatedProperties
Original file line number Diff line number Diff line change @@ -18,6 +18,12 @@ public async Task<RetrievedPage> CreateAsync(CreatedPage page)
1818 return await _client . PostAsync < RetrievedPage > ( PagesApiUrls . Create ( ) , page ) ;
1919 }
2020
21+ public async Task < RetrievedPage > RetrieveAsync ( string pageId )
22+ {
23+ var url = PagesApiUrls . Retrieve ( pageId ) ;
24+ return await _client . GetAsync < RetrievedPage > ( url ) ;
25+ }
26+
2127 public async Task < RetrievedPage > UpdatePropertiesAsync (
2228 string pageId ,
2329 IDictionary < string , PropertyValue > updatedProperties )
You can’t perform that action at this time.
0 commit comments