angular retrieving user_id but not the name for the user

When a user submits data to a form, it retrieves the post with the title,body and name just fine

however when i refresh the page, the title and body stays in tack but the name for user disappears.

when i use post.user_id instead of post.name it shows the user id on refresh but not the same for the name.

note: submitting a post works fine, and i do not need to specify a name for the user it justs know which user it is by who is logged in. I'm using laravel.

here is the html

    <div id="mypost" class="col-md-8 panel-default" ng-repeat="post in myposts" >
        <div id="eli-style-heading" class="panel-heading"><% post.title %></div>
            <div class="panel-body panel">
                <figure>
                    <p> <% post.body %></p>
                    by:<p><% post.name %></p>

                </figure>
            </div>
    </div>

Controller in which angular calls to retrieve posts and stores post

 public function getPosts()
{

    $posts = Post::all();
    return json_encode($posts);
}

public function storePost(Request $request)
{
    $data = request()->validate([
     'title' => 'required|max:120',
     'body' => 'required|max:1000'
    ]);

    $data['user_id'] = auth()->user()->id;
    $data['name'] = auth()->user()->name;

    $post = Post::create($data);

    $response = new Response(json_encode($data));
    $response->headers->set('Content-Type', 'application/json'); 


    // return redirect('/home')->withMessage('A new post was created.');

    return $response;
}

Main.js

$scope.myposts = {};

$scope.addPost = function(){

    $http.post('/auth/post', {
        title: $scope.post.title,
        body: $scope.post.body, 
        name:$scope.post.name

    }).then(function(data, status, headers, config){
        console.log(data);  
        $scope.myposts.push(data.data);


    });

    $scope.post.title = '';
    $scope.post.body = '';

};

$scope.getPosts = function(){

    $http.get('/auth/posts').then(function(data){
        $scope.myposts = data.data;
    }).then(function(data, status, header, config){
    });



};


$scope.getPosts();