Alfresco Index of Web Scripts Lifecycle '/public_api'
Alfresco Community v3.2.0 (2039)
7 Web Scripts

Back to Web Scripts Home

Up to lifecycle /

Login
GET /alfresco/service/api/login?u={username}&pw={password?}
---
Login and establish a ticket.
Input
u
cleartext username (must be URL encoded)
pw
cleartext password (must be URL encoded)

Returns the new authentication ticket.
---
Authentication:none
Transaction:required
Format Style:any
Default Format:xml
Lifecycle:public_api
Id:org/alfresco/repository/login.get
Descriptor:classpath:alfresco/templates/webscripts/org/alfresco/repository/login.get.desc.xml

Login (POST)
POST /alfresco/service/api/login
---
Login and establish a ticket.
Input
JSON Data Object.
username
cleartext username
password
cleartext password

Returns the new authentication ticket.
---
Authentication:none
Transaction:required
Format Style:any
Default Format:json
Lifecycle:public_api
Id:org/alfresco/repository/login.post
Descriptor:classpath:alfresco/templates/webscripts/org/alfresco/repository/login.post.desc.xml

Logout
DELETE /alfresco/service/api/login/ticket/{ticket}
---
Logout, Delete Login Ticket.
After the user has logged out the ticket is no longer valid and subsequent attempts to use it will fail.
---
Authentication:user
Transaction:required
Format Style:any
Default Format:xml
Lifecycle:public_api
Id:org/alfresco/repository/loginticket.delete
Descriptor:classpath:alfresco/templates/webscripts/org/alfresco/repository/loginticket.delete.desc.xml

Validate Login Ticket
GET /alfresco/service/api/login/ticket/{ticket}
---
Validates the specified ticket is still valid.
The ticket may be invalid, or expired, or the user may have been locked out.
For security reasons this script will not validate the ticket of another user.
  • If the ticket is valid retuns, STATUS_SUCCESS (200)
  • If the ticket is not valid return, STATUS_NOT_FOUND (404)
  • If the ticket does not belong to the current user, STATUS_NOT_FOUND (404)
---
Authentication:user
Transaction:required
Format Style:any
Default Format:xml
Lifecycle:public_api
Id:org/alfresco/repository/loginticket.get
Descriptor:classpath:alfresco/templates/webscripts/org/alfresco/repository/loginticket.get.desc.xml

Content Delete (deleteContent)
DELETE /alfresco/service/api/node/content{property}/{store_type}/{store_id}/{id}
DELETE /alfresco/service/api/path/content{property}/{store_type}/{store_id}/{id}
DELETE /alfresco/service/api/avmpath/content{property}/{store_id}/{id}
DELETE /alfresco/service/api/node/{store_type}/{store_id}/{id}/content{property}
DELETE /alfresco/service/api/path/{store_type}/{store_id}/{id}/content{property}
---
---
Authentication:guest
Transaction:required
Format Style:argument
Default Format:atomentry
Lifecycle:public_api
Id:org/alfresco/repository/store/content.delete
Descriptor:classpath:alfresco/templates/webscripts/org/alfresco/repository/store/content.delete.desc.xml

Content Retrieval (getContent)
GET /alfresco/service/api/node/content{property}/{store_type}/{store_id}/{id}?a={attach?}
GET /alfresco/service/api/path/content{property}/{store_type}/{store_id}/{id}?a={attach?}
GET /alfresco/service/api/avmpath/content{property}/{store_id}/{id}?a={attach?}
GET /alfresco/service/api/node/{store_type}/{store_id}/{id}/content{property}?a={attach?}
GET /alfresco/service/api/path/{store_type}/{store_id}/{id}/content{property}?a={attach?}
---
The service returns the content-stream for a document. This is the only service that returns content-stream.

Inputs:

ID documentId: Document to return the content-stream
(Optional) Integer offset:
(Optional) Integer length:

Outputs:

Byte[] stream

Notes:

Some CMIS protocol bindings MAY choose not to explicitly implement a “getContentStream” method, in cases where the protocol itself provides built-in mechanisms for retrieving byte streams. (E.g. in the ATOM/REST binding, content streams may be retrieved via standard HTTP gets on an “edit-media” URL, rather than a CMIS-specific “getContentStream” URL). See Part II of the CMIS specification for additional details.
Each CMIS protocol binding will provide a way for fetching a sub-range within a content stream, in a manner appropriate to that protocol.
---
Authentication:guest
Transaction:required
Format Style:argument
Default Format:Determined at run-time
Lifecycle:public_api
Id:org/alfresco/repository/store/content.get
Descriptor:classpath:alfresco/templates/webscripts/org/alfresco/repository/store/content.get.desc.xml

File Upload
POST /alfresco/service/api/upload
---
Upload file content and meta-data into repository.
HTML form data
  • filedata, (mandatory) HTML type file
  • siteid
  • containerid
  • uploaddirectory
  • updatenoderef
  • filename
  • description
  • contenttype
  • majorversion
  • overwrite
  • thumbnails

Return content
  • nodeRef

Return status: STATUS_OK (200)
---
Authentication:user
Transaction:required
Format Style:any
Default Format:json
Lifecycle:public_api
Id:org/alfresco/repository/upload/upload.post
Descriptor:classpath:alfresco/templates/webscripts/org/alfresco/repository/upload/upload.post.desc.xml