---
title: "Using Server-Side Scripts on API Endpoints | DreamFactory"
description: "The general model for server-side scripting: attach custom logic to any API endpoint, on either side of the request, regardless of which runtime you write…"
url: "https://www.dreamfactory.com/videos/server-side-scripts"
---

[Home](https://www.dreamfactory.com/) › [Videos](https://www.dreamfactory.com/videos) › Using Server-Side Scripts on API Endpoints

# Using Server-Side Scripts on API Endpoints

Tutorial·23 February 2016·8 min 3 sec

The general model for server-side scripting: attach custom logic to any API endpoint, on either side of the request, regardless of which runtime you write it in. Worth watching before the language-specific scripting tutorials.

**Recorded in 2016.** The concepts still apply, but the interface shown predates the current DreamFactory release. Some steps may differ in the current release.

## What you’ll learn

* Attaching a script to any generated API endpoint
* Running logic before or after the request is handled
* The shared model behind the PHP, Python, and Node.js runtimes

## Related article

* [DreamFactory 2.1 released, includes OpenAPI spec upgrade](https://blog.dreamfactory.com/dreamfactory-2-1-release-news)

[Book a Demo](https://www.dreamfactory.com/demo)[More on our YouTube channel](https://www.youtube.com/@DreamfactoryAPI)

## More videos

* [Adding API Aliases to SQL Fields](https://www.dreamfactory.com/videos/sql-field-api-aliases)
* [Creating Calculated Virtual SQL Fields](https://www.dreamfactory.com/videos/calculated-virtual-sql-fields)
* [Adding Your Own Custom API](https://www.dreamfactory.com/videos/custom-api-endpoints)
* [Setting Up the Address Book Sample Application](https://www.dreamfactory.com/videos/address-book-sample-app)

[Browse all videos ›](https://www.dreamfactory.com/videos)

Video: https://www.youtube.com/watch?v=EYI7ImZx1eA
