Password Pusher API leagan 2
BÉITEDoiciméadacht chuimsitheach REST API le haghaidh comhtháthú Password Pusher isteach i do chuid feidhmchlár
Fógra Béite: Tá API v2 i mbéite faoi láthair. Cé gur dhéanaimid gach iarracht chun cobhsaíocht a chinntiú, d'fhéadfadh athruithe bristeacha a bheith ann roimh an scaoileadh deiridh. Cuirimid fáilte roimh d'aiseolas!
Iarratais
Cumasaíonn iarratais cumarsáid shlán, dhá bhealach chun faisnéis íogair a bhailiú. Cruthaigh iarratas le URL rúnda, roinn é le duine ar bith, agus faigh freagraí slána ina bhfuil téacs nó comhaid—gan sonraí íogaire a nochtadh i ríomhphost, i gcomhrá ná i logaí.
Foirfe chun dintiúir, eochracha API, doiciméid rúnda, nó aon fhaisnéis íogair a bhailiú ó chomhghleacaithe, ó chliaint, nó ó chustaiméirí. Déantar freagraí a chriptiú go huathoibríoch agus a scriosadh go huathoibríoch tar éis tréimhse shonraithe chun nochtadh sonraí a íoslaghdú. Tá rianú iomlán saolré ar fáil i logaí iniúchta gach iarratais.
Tá trí staid ag iarratais:
POST /api/v2/requests
Cruthaíonn iarratas nua. Éilíonn fíordheimhniú.
Request Body (JSON)
{
"request": {
"request": "Please provide your hosting information here.",
"close_after_duration": 8,
"passphrase": "optional_passphrase",
"name": "Database Access Request",
"note": "Internal note",
"retrieval_step": true,
"include_requestor": false,
"response_file_attachments": true
}
}
Request Body with Files (multipart/form-data)
curl -X POST https://eu.pwpush.com/api/v2/requests \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-F "request[request]=Please provide your hosting information here." \
-F "request[close_after_duration]=8" \
-F "request[name]=Database Access Request" \
-F "request[files][]=@/path/to/document.pdf" \
-F "request[files][]=@/path/to/spreadsheet.xlsx"
Note: When attaching files, use multipart/form-data format. Multiple files can be attached using request[files][].
Parameters
| Parameter | Type | Description |
|---|---|---|
request
ag teastáil
|
string | An téacs/teachtaireacht iarrata le roinnt |
close_after_duration
roghnach
|
integer (0-17) | Uimhir Fad - cathain is ceart an t-iarratas a dhúnadh |
passphrase
roghnach
|
string | Éiligh ar fhaighteoirí an frása faire seo a iontráil le go bhfeicfidh siad é |
name
roghnach
|
string | Ainm a thaispeántar sa phainéal rialaithe, sna fógraí agus sna ríomhphoist |
note
roghnach
|
string | Nóta inmheánach (le feiceáil ag an cruthaitheoir amháin) |
retrieval_step
roghnach
|
boolean | Cabhraíonn sé le córais comhrá agus scanóirí URL a sheachaint ó bheith ag ithe suas radharcanna |
include_requestor
roghnach
|
boolean | Cuir faisnéis an iarratóra san iarratas |
response_file_attachments
roghnach
|
boolean | Ceadaigh ceangaltáin chomhaid i bhfreagraí |
files
roghnach
|
array | Comhad(anna) le huaslódáil agus le ceangal leis an iarratas |
notify_emails_to
roghnach
|
string | Seoltaí ríomhphoist le cur ar an eolas nuair a chruthaítear iarratas (scartha le camóga) |
notify_emails_to_locale
roghnach
|
string | Teanga áitiúil le fógra(í) ríomhphoist a sheoladh inti |
account_id
roghnach
|
integer | An t-aitheantas cuntais a mbeidh an t-iarratas ceangailte leis |
Luachanna Fad le haghaidh close_after_duration
Iarratas Samplach
curl -X POST https://eu.pwpush.com/api/v2/requests \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"request": {
"request": "Please provide your hosting information here.",
"close_after_duration": 8,
"passphrase": "optional_passphrase",
"name": "Database Access Request"
}
}'
require 'net/http'
require 'json'
require 'uri'
uri = URI('https://eu.pwpush.com/api/v2/requests')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
request = Net::HTTP::Post.new(uri.path)
request['Authorization'] = 'Bearer YOUR_API_TOKEN'
request['Content-Type'] = 'application/json'
request.body = {
request: {
request: 'Please provide your hosting information here.',
close_after_duration: 8,
passphrase: 'optional_passphrase',
name: 'Database Access Request'
}
}.to_json
response = http.request(request)
puts response.body
import requests
import json
url = 'https://eu.pwpush.com/api/v2/requests'
headers = {
'Authorization': 'Bearer YOUR_API_TOKEN',
'Content-Type': 'application/json'
}
data = {
'request': {
'request': 'Please provide your hosting information here.',
'close_after_duration': 8,
'passphrase': 'optional_passphrase',
'name': 'Database Access Request'
}
}
response = requests.post(url, headers=headers, json=data)
print(response.json())
$headers = @{
'Authorization' = 'Bearer YOUR_API_TOKEN'
'Content-Type' = 'application/json'
}
$body = @{
request = @{
request = 'Please provide your hosting information here.'
close_after_duration = 8
passphrase = 'optional_passphrase'
name = 'Database Access Request'
}
} | ConvertTo-Json -Depth 10
$response = Invoke-RestMethod -Uri 'https://eu.pwpush.com/api/v2/requests' `
-Method Post `
-Headers $headers `
-Body $body
$response | ConvertTo-Json
GET /api/v2/requests/:url_token
Aisghabhann sé seo ábhar iarrata oscailte nó réidh. Féadfaidh sé seo an t-iarratas a dhúnadh má tá sé cumraithe le dúnadh tar éis líon áirithe radharcanna.
Iarratas Samplach
curl -X GET https://eu.pwpush.com/api/v2/requests/orpw2wkg00vpn0a
Iarratas Samplach le Pasfrása
curl -X GET "https://eu.pwpush.com/api/v2/requests/orpw2wkg00vpn0a?passphrase=your_passphrase"
Freagra Samplach (Iarratas Oscailte)
{
"close_after_duration": 8,
"url_token": "orpw2wkg00vpn0a",
"retrieval_step": true,
"passphrase": "optional_passphrase",
"created_at": "2023-10-27T10:00:00.000Z",
"updated_at": "2023-10-27T10:00:00.000Z",
"state": "open",
"include_requestor": false,
"response_file_attachments": true,
"close_after_at": "2023-11-04T10:00:00.000Z",
"days_remaining": 8,
"json_url": "https://eu.pwpush.com/r/orpw2wkg00vpn0a.json",
"html_url": "https://eu.pwpush.com/r/orpw2wkg00vpn0a",
"request": "Please provide your hosting information here.",
"response": null,
"files": []
}
Freagra Samplach (Iarratas Réidh)
{
"close_after_duration": 8,
"url_token": "orpw2wkg00vpn0a",
"retrieval_step": true,
"passphrase": "optional_passphrase",
"created_at": "2023-10-27T10:00:00.000Z",
"updated_at": "2023-10-27T10:00:00.000Z",
"state": "ready",
"include_requestor": false,
"response_file_attachments": true,
"close_after_at": "2023-11-04T10:00:00.000Z",
"days_remaining": 8,
"json_url": "https://eu.pwpush.com/r/orpw2wkg00vpn0a.json",
"html_url": "https://eu.pwpush.com/r/orpw2wkg00vpn0a",
"request": null,
"response": "The API key is: sk_live_1234567890",
"files": []
}
Nóta: Má tá frása faire san iarratas, cuir san áireamh é mar pharaiméadar fiosrúcháin: ?passphrase=your_passphrase. Meastar gur radharc é iarratas a aisghabháil agus féadfar an t-iarratas a dhúnadh má shroicheann sé a theorainn radharcanna.
PATCH /api/v2/requests/:url_token/respond
Freagraíonn sé iarratas oscailte, ag athrú a stádais go 'réidh'.
Request Body (JSON)
{
"request": {
"response": "The API key is: sk_live_1234567890"
}
}
Request Body with Files (multipart/form-data)
curl -X PATCH https://eu.pwpush.com/api/v2/requests/orpw2wkg00vpn0a/respond \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-F "request[response]=The API key is: sk_live_1234567890" \
-F "request[files][]=@/path/to/response_doc.pdf"
Note: When attaching files, use multipart/form-data format. Multiple files can be attached using request[files][].
Paraiméadair
| Paraiméadar | Cineál | Cur síos |
|---|---|---|
response
ag teastáil
|
string | An téacs/teachtaireacht freagartha ar an iarratas |
files
roghnach
|
array | Comhad(anna) le ceangal leis an bhfreagra (éilíonn response_file_attachments: true ar an iarratas) |
Nóta: Ní féidir ach le hiarratais atá sa staid "oscailte" freagraí a fháil. Nuair a chuirtear freagra isteach, bogann an t-iarratas go dtí an staid "réidh" agus ní féidir glacadh le freagraí breise.
GET /api/v2/requests/:url_token/preview
Tugann sé URL rúnda láncháilithe iarrata ar ais gan an t-ábhar a aisghabháil.
Iarratas Samplach
curl -X GET https://eu.pwpush.com/api/v2/requests/orpw2wkg00vpn0a/preview
Freagra Samplach
{
"url": "https://eu.pwpush.com/r/orpw2wkg00vpn0a"
}
GET /api/v2/requests/:url_token/audit
Seolann sé log iniúchta ar ais le haghaidh iarratais. Éilíonn sé fíordheimhniú agus úinéireacht.
Paraiméadair Iarratais:
page (roghnach): Uimhir leathanaigh le haghaidh uimhriú leathanaigh.
- Réamhshocrú:
1(an chéad leathanach) - Raon:
1go200 - Tugann sé suas le 50 iontráil loga iniúchta ar ais in aghaidh an leathanaigh
- Sampla:
?page=2chun an dara leathanach a aisghabháil
Iarratas Samplach
curl -X GET https://eu.pwpush.com/api/v2/requests/orpw2wkg00vpn0a/audit \
-H "Authorization: Bearer YOUR_API_TOKEN"
Freagra Samplach
{
"logs": [
{
"ip": "192.168.1.100",
"user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36",
"referrer": null,
"kind": "creation",
"created_at": "2023-10-27T10:00:00.000Z",
"updated_at": "2023-10-27T10:00:00.000Z"
},
{
"ip": "192.168.1.101",
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36",
"referrer": "https://example.com",
"kind": "view",
"created_at": "2023-10-27T10:05:00.000Z",
"updated_at": "2023-10-27T10:05:00.000Z"
},
{
"ip": "192.168.1.102",
"user_agent": "Mozilla/5.0 (iPhone; CPU iPhone OS 14_0 like Mac OS X) AppleWebKit/605.1.15",
"referrer": null,
"kind": "response",
"created_at": "2023-10-27T10:10:00.000Z",
"updated_at": "2023-10-27T10:10:00.000Z"
}
]
}
Nóta: An kind Léiríonn an réimse an cineál gníomhaíochta atá logáilte. Áirítear ar na luachanna coitianta: creation, view, response, close, failed_passphrase, agus failed_view.
DELETE /api/v2/requests/:url_token
Dúnann sé iarratas láithreach agus scriosann sé go buan na sonraí íogaire go léir a bhaineann leis. Ní féidir an gníomh seo a aisiompú agus ní féidir é a chealú. Éilíonn sé fíordheimhniú agus úinéireacht.
Iarratas Samplach
curl -X DELETE https://eu.pwpush.com/api/v2/requests/orpw2wkg00vpn0a \
-H "Authorization: Bearer YOUR_API_TOKEN"
Freagra Samplach
{
"close_after_duration": null,
"url_token": "orpw2wkg00vpn0a",
"retrieval_step": false,
"passphrase": null,
"created_at": "2023-10-27T10:00:00.000Z",
"updated_at": "2023-10-27T10:15:00.000Z",
"state": "closed",
"include_requestor": false,
"response_file_attachments": false,
"close_after_at": null,
"days_remaining": null,
"json_url": "https://eu.pwpush.com/r/orpw2wkg00vpn0a.json",
"html_url": "https://eu.pwpush.com/r/orpw2wkg00vpn0a",
"account_id": 1,
"note": null,
"name": null,
"request": null,
"response": null,
"files": []
}
GET /api/v2/requests/active
Tugann sé liosta leathanaigh de d’iarratais ghníomhacha (oscailte nó réidh) ar ais. Éilíonn sé fíordheimhniú.
GET /api/v2/requests/open
Tugann sé liosta leathanaigh de do chuid iarratais oscailte ar ais. Éilíonn sé fíordheimhniú.
GET /api/v2/requests/ready
Seolann sé liosta leathanaigh de do chuid iarratais réidh ar ais. Éilíonn sé fíordheimhniú.
GET /api/v2/requests/closed
Tugann sé liosta leathanaigh de do chuid iarratais dúnta ar ais. Éilíonn sé fíordheimhniú.
Paraiméadair Iarratais:
page (roghnach): Uimhir leathanaigh le haghaidh uimhriú leathanaigh.
- Réamhshocrú:
1(an chéad leathanach) - Raon:
1go200 - Tuairiscíonn suas le 50 iarratas in aghaidh an leathanaigh
- Sampla:
?page=2chun an dara leathanach a aisghabháil
Stáit Iarratais
Oscail
Tá an t-iarratas cruthaithe agus táthar ag fanacht le freagra. Tá téacs an iarratais le feiceáil, ach níl aon fhreagra curtha ar fáil fós.
Réidh
Tá freagra tugtha ar an iarratas agus tá an t-ualach freagartha ann anois. Níl téacs an iarratais le feiceáil a thuilleadh, ach tá an freagra ar fáil lena aisghabháil.
Dúnta
Tá an t-iarratas láimhseáilte agus tá na sonraí íogaire go léir (an t-iarratas agus an freagra araon) scriosta go buan. Ní féidir an staid seo a aisiompú.
Iarratas Samplach (Gníomhach)
curl -X GET https://eu.pwpush.com/api/v2/requests/active \
-H "Authorization: Bearer YOUR_API_TOKEN"
Iarratas Samplach (Oscailte)
curl -X GET https://eu.pwpush.com/api/v2/requests/open \
-H "Authorization: Bearer YOUR_API_TOKEN"
Iarratas Samplach (Réidh)
curl -X GET https://eu.pwpush.com/api/v2/requests/ready \
-H "Authorization: Bearer YOUR_API_TOKEN"
Iarratas Samplach (Dúnta)
curl -X GET https://eu.pwpush.com/api/v2/requests/closed \
-H "Authorization: Bearer YOUR_API_TOKEN"
Freagra Samplach
[
{
"close_after_duration": 7,
"url_token": "abc123xyz789",
"retrieval_step": false,
"passphrase": null,
"created_at": "2023-10-27T10:00:00.000Z",
"updated_at": "2023-10-27T10:00:00.000Z",
"state": "open",
"include_requestor": false,
"response_file_attachments": false,
"close_after_at": "2023-11-03T10:00:00.000Z",
"days_remaining": 7,
"json_url": "https://eu.pwpush.com/r/abc123xyz789.json",
"html_url": "https://eu.pwpush.com/r/abc123xyz789",
"account_id": 1,
"note": null,
"name": null
},
{
"close_after_duration": 7,
"url_token": "def456uvw012",
"retrieval_step": false,
"passphrase": null,
"created_at": "2023-10-26T15:30:00.000Z",
"updated_at": "2023-10-27T09:00:00.000Z",
"state": "ready",
"include_requestor": false,
"response_file_attachments": false,
"close_after_at": "2023-11-02T15:30:00.000Z",
"days_remaining": 6,
"json_url": "https://eu.pwpush.com/r/def456uvw012.json",
"html_url": "https://eu.pwpush.com/r/def456uvw012",
"account_id": 1,
"note": null,
"name": null
}
]
Nóta: An /active iarratais ar ais críochphointe sa dá cheann open agus ready stáit. Úsáid /open nó /ready críochphointí le scagadh de réir stáit shonraigh.
Nuashonraithe go deireanach: July 12, 2026