aboutsummaryrefslogtreecommitdiffhomepage
path: root/routes/note.php
blob: 9c5e507a016669312a38c198b4a180704aaf17d5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<?php

use WpfTest\Router;

Router::getInstance()->mount('/post/:id', function (array $args) {
    json_response([
        'type' => 'note',
        'self' => path_to_uri('/post/' . $args['id']),
        'created' => '2024-12-06T20:14:00+00:00',
        'author' => path_to_uri('/user/winter'),
        'plainContent' => 'meow :3',
        'language' => 'eng',
        'inReplyTo' => null,
        'threadApex' => path_to_uri('/post/' . $args['id']),
        'privacy' => [
            'scope' => 'public',
            'indexable' => true
        ]
    ]);
});