Professional Documents
Culture Documents
EPFO Employer Based API - v1
EPFO Employer Based API - v1
Request
Metho http://ec2-13-233-217-249.ap-south-
d 1.compute.amazonaws.com:4500/epfo/generate-post/
POST
PO client_id str
ST client_secr ing
et str
ing
print(response.json())
Response
'expires_in': 900,
'created_time': 1562754835},
'code': 'success',
'success': True}
Generate transaction id
We now use the generated “access_token” in the previous step as “Authorization” header.
Other than this header, there is no other post parameter. Make a get request to
generate the transaction id.
Request
Method http://ec2-13-233-217-249.ap-south-
1.compute.amazonaws.com:4500/epfo/transaction-get/
GET
Type Header Values
print (response2.json())
Response
{'message': 'EPFOEMPLOYER181264392702507931100529319290713666160',
'code': 'success',
'success': 'True'}
Metho http://ec2-13-233-217-249.ap-south-
d 1.compute.amazonaws.com:4500/epfo/submit-post/?
txnid=<transactionid>
epfoemployer-pwd String
employee-uan string
print(response3.json())
Response
{'code': 'success',
'message': [{'uan':
101076072949, 'name':
'MOHANA SUNDARI S',
'company': 'SOBHA
LIMITED', 'doj':
'25/04/2018', 'doe':
'NOT_AVAILABLE'}, {'uan':
101076072949, 'name':
'MOHANA SUNDARI S',
'company': 'VEN
CONSULTING INDIA PVT
LTD', 'doj':
'27/02/2017', 'doe':
'28/02/2018'}],
'success': True}
false
invalid_usr_pwd invalid username or
password
false
internal_error invalid transactionid
GET report
It takes around 60 seconds to complete report generation at the backend after the previous step
of submitting credentials. A simple get request along with access token and transactionid
information can be used to obtain the report. We can obtain the report in ‘json’ format by using
the URL. See python sample code below to obtain the report.
By default, the transactionid and json report associated with it expires in 20 minutes.
Request
GET
print (response4.json())
Response
{'code': 'success', 'message': [{'uan': 101076072949, 'name': 'MOHANA SUNDARI S',
'company': 'SOBHA LIMITED', 'doj': '25/04/2018', 'doe': 'NOT_AVAILABLE'}, {'uan':
101076072949, 'name': 'MOHANA SUNDARI S', 'company': 'VEN CONSULTING INDIA PVT
LTD', 'doj': '27/02/2017', 'doe': '28/02/2018'}], 'success': True}