File tree Expand file tree Collapse file tree 2 files changed +45
-0
lines changed Expand file tree Collapse file tree 2 files changed +45
-0
lines changed Original file line number Diff line number Diff line change
1
+ {
2
+ "testExplorer.useNativeTesting" : true
3
+ }
Original file line number Diff line number Diff line change 1
1
defmodule ThinNotionApi.Pages do
2
2
import ThinNotionApi.Base
3
3
4
+ @ doc """
5
+ Retrieves a Page object using the ID specified.
6
+
7
+ Responses contains page properties, not page content. To fetch page content, use the retrieve block children endpoint.
8
+
9
+ ## Examples:
10
+ iex> ThinNotionApi.Pages.retrieve_page("9b4a624d5a18482ab2187e54166edda7")
11
+ {:ok,
12
+ %{
13
+ "archived" => false,
14
+ "created_time" => "2021-06-11T20:34:00.000Z",
15
+ "id" => "9b4a624d-5a18-482a-b218-7e54166edda7",
16
+ "last_edited_time" => "2021-07-30T21:03:00.000Z",
17
+ "object" => "page",
18
+ "parent" => %{"type" => "workspace", "workspace" => true},
19
+ "properties" => %{
20
+ "title" => %{
21
+ "id" => "title",
22
+ "title" => [
23
+ %{
24
+ "annotations" => %{
25
+ "bold" => false,
26
+ "code" => false,
27
+ "color" => "default",
28
+ "italic" => false,
29
+ "strikethrough" => false,
30
+ "underline" => false
31
+ },
32
+ "href" => nil,
33
+ "plain_text" => "Thin Notion Test Workspace",
34
+ "text" => %{"content" => "Thin Notion Test Workspace", "link" => nil},
35
+ "type" => "text"
36
+ }
37
+ ],
38
+ "type" => "title"
39
+ }
40
+ },
41
+ "url" => "https://www.notion.so/Thin-Notion-Test-Workspace-9b4a624d5a18482ab2187e54166edda7"
42
+ }
43
+ }
44
+ """
45
+ @ spec retrieve_page ( String . t ( ) ) :: map ( )
4
46
def retrieve_page ( page_id ) do
5
47
get ( "pages/#{ page_id } " )
6
48
end
You can’t perform that action at this time.
0 commit comments