---
title: "Preview social completion REST API | HitKeep"
description: "Reference for the HitKeep REST API operation Preview social completion, including request parameters, responses, and authentication notes."
canonical: "https://hitkeep.com/api/operations/apiauthsocialpreview/"
---

# Preview social completion REST API

POST

/api/auth/social/preview

FetchcURL

```
const url = 'http://127.0.0.1:25737/api/auth/social/preview';
const options = {
  method: 'POST',
  headers: {'Content-Type': 'application/json'},
  body: '{"completion_token":"example","email":"hello@example.com"}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```
curl --request POST \
  --url http://127.0.0.1:25737/api/auth/social/preview \
  --header 'Content-Type: application/json' \
  --data '{ "completion_token": "example", "email": "hello@example.com" }'
```

-

Returns safe provider and observed-email metadata for a still-valid completion token. Provider subjects are never returned.

## Request Bodyrequired

application/json

object

**completion_token**

required

string

**email**

HitKeep target email required for a first unauthenticated Microsoft link.

string format: email

##### Examplegenerated

```
{
  "completion_token": "example",
  "email": "hello@example.com"
}
```

## Responses

### 200

Social completion preview

application/json

object

**display_name**

required

string

**email_confirmation_required**

required

Whether this completion requires the user to confirm a HitKeep email before continuing.

boolean

**email_verified**

required

boolean

**flow**

required

string

Allowed values: login signup invite

**observed_email**

string format: email

**provider**

required

string

Allowed values: google github microsoft

##### Example

```
{
  "flow": "login",
  "provider": "google"
}
```

### 409

Completion token invalid, expired, or already consumed

application/json

object

**message**

string

##### Examplegenerated

```
{
  "message": "example"
}
```

[Previous Confirm Microsoft social identity](https://hitkeep.com/api/operations/apiauthsocialconfirm/)[Next List social sign-in providers](https://hitkeep.com/api/operations/apiauthsocialproviders/)
