Questions tagged [alfresco-webscripts]

Web scripts provide a way to write small extensions to Alfresco using JavaScript and FreeMarker.

Alfresco web scripts provide a unique way to programmatically interact with the Alfresco content application server. Unlike other interfaces exposed by Alfresco, web scripts offer a RESTful API for the content residing in the content repository. The REST (Representational State Transfer) web architecture is based on HTTP requests and responses, URIs (Uniform Resource Identifiers), and document types. Web scripts let you implement your own RESTful API without tooling or Java knowledge, requiring only a text editor. This approach to developing an Alfresco API means that web scripts offer many advantages over existing technologies, including ease and speed of development, and flexibility in API design. By focusing on the RESTful architectural style, web scripts let you build custom URI-identified and HTTP accessible content management web services backed by the Alfresco content application server.

Web scripts provide RESTful access to content held within your Alfresco content repository. You can place controls on your content to manage it and provide uniform access for a wide variety of client applications and services, such as a browser, portal, search engine, or custom application. Because of the inherent distributed nature of this interface, all Alfresco content repositories within the enterprise can resemble one logical collection of inter-related documents (like the web), letting you apply web technologies such as caching, authentication, proxies, and negotiation to your repository resources.

You can build your own RESTful interface using lightweight scripting technologies (such as JavaScript and FreeMarker), allowing you to arbitrarily map any content in the repository to resources on the web, or you can use out-of-the-box web scripts that already encapsulate many of the mappings. The Alfresco CMIS (Content Management Interoperability Services) AtomPub binding is implemented as a series of web scripts.

You can use web scripts for various solutions, such as:

  • Integrating Alfresco with third party systems Providing feeds
  • Developing data services Developing UI services such as portlets
  • Customizing search Acting as a back-end to client tools, such as
  • Orbeon Forms Integrating with Microsoft Office
  • Developing Facebook applications
  • Building UI components in Alfresco Surf

Source: http://docs.alfresco.com/5.1/concepts/ws-overview.html

352 questions
1
vote
1 answer

exclude a certain path from all user searches

Unfortunately we have a special folder named "_archive" in our repository everywhere. This folder has its purpose. But: When searching for content/documents we want to exclude it and every content beneath "_archive". So, what i want is to exclude…
1
vote
1 answer

Alfresco database delete records related to archived store (contentStore/ archive space)

Whenever, we delete a file in Alfresco Document library that file moves to Trashcan and the files are marked as archived in DB (moved to archived store). If the user deletes the file in Trashcan then after 14 days the file will be moved from…
sabtharishi
  • 3,141
  • 5
  • 24
  • 27
1
vote
1 answer

Deleting a property from a node in Alfresco

I want to remove a property from a node. Using "removeProperty(NodeRef nodeRef, QName qname)" i can remove it, but i don't know will it cause any problem(like data correption, indexing issue or something ). Can anyone please help me
1
vote
1 answer

To delete the property value in Alfresco custom model

I need to delete the node property in alfresco 5.0.d version. While trying to delete I am getting this below error: Web Script Status 405 - Method Not Allowed The alfresco webscript file: function main() { // Get the username var userName =…
1
vote
1 answer

Get property of object Alfresco

I'm using Alfresco 5.1 Community, and i'm trying to get a property of an object for example, in the user we have: "{http://www.alfresco.org/model/content/1.0}companytelephone" If I want to get the value of this property, how can I obtain this in…
Petter S
  • 49
  • 8
1
vote
1 answer

Alfresco java webscript has null ServiceRegistry

I have create an All-in-one amp in alfresco. Inside repo-amp l have create a java webscript and I want to get the file name as json return of specific workspace. The java code following . . . public class Fields extends AbstractWebScript { …
mr antoni
  • 595
  • 1
  • 6
  • 17
1
vote
2 answers

Alfresco share ClientAbortException

Sometimes when we open folder, Alfresco shows spinning wheel and never opens the folder. The log has below exception. 2016-03-08 11:45:40,652 INFO [webscripts.connector.RemoteClient] [http-bio-8080-exec-494] Exception calling (GET)…
sabtharishi
  • 3,141
  • 5
  • 24
  • 27
1
vote
2 answers

Custom form new user error in Alfresco

How can I make a custom user profile ? I want to add a new field to the users in Alfresco... I try to use this : http://ecmarchitect.com/archives/2012/02/27/1555, the code :…
PRVS
  • 1,612
  • 4
  • 38
  • 75
1
vote
1 answer

Share file of a workflow with assignees - Alfresco

I'm making a custom workflow, and I want to share the file that I create a workflow with the assignees, because otherwise, the users only access the file through "I've recently modified" and when the task is done, the file disappears. How can I…
PRVS
  • 1,612
  • 4
  • 38
  • 75
1
vote
2 answers

Get NodeRef of a workflow task Alfresco

I create a workflow, and when I go to the task-edit page: I'm trying to obtain the nodeRef of the file (latexexemplo-2.pdf) of the workflow task: http://localhost:8080/share/page/task-edit?taskId=activiti$20649 I'm trying to make this way: var…
PRVS
  • 1,612
  • 4
  • 38
  • 75
1
vote
1 answer

Custom record identifier using alfresco record management

Presently in alfresco records management Unique identifier is numeric number. Need to customize the unique identifier to support alpha numeric.
1
vote
1 answer

how to get respose of data webscript in share webscript js file

I have one data webscript at alfresco side which return json response. i want this json response in share webscript to display that json data on share. following is the my code written in getLocation.get.js file @ share. var result1 = new…
Arjun Patil
  • 111
  • 9
1
vote
2 answers

Auto-login to Alfresco via JavaScript

I'm new to using Alfresco Community 5.0.d, and I'm attempting to allow a specific user to log in without going through the login page form. Specifically, I need to set up a button that, when it is clicked, the underlying JavaScript gets the session…
xserrat
  • 1,429
  • 1
  • 13
  • 12
1
vote
1 answer

Get file (401 unauthorized) - Alfresco

I get a file in Alfresco, with link for example: http://localhost:8080/share/proxy/alfresco/workspace/SpacesStore/c9d187e8-aec5-4177-9587-a5b924e514cd/exemplo.pdf with XMLHttpRequest on javascript and I don't have problems. But i'm trying to do this…
PRVS
  • 1,612
  • 4
  • 38
  • 75
1
vote
1 answer

Alfresco - Get username in workflow

I'm searching for the username of assignees when I create on a workflow... I use this: public void notify(DelegateExecution execution) { // get value of property mymodel:myproperty Object assignees = execution.getVariable("bpm_assignees");…
PRVS
  • 1,612
  • 4
  • 38
  • 75