File size: 371 Bytes
1e92f2d
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
import wpcom from 'calypso/lib/wp';

export interface ResendEmailVerificationBody {
	from?: string; // Helps decide the url of the page after confirmation.
}

export function useSendEmailVerification( body: ResendEmailVerificationBody = {} ) {
	return async () => {
		return wpcom.req.post( '/me/send-verification-email', {
			apiVersion: '1.1',
			...body,
		} );
	};
}