# Class UrlMap (1.18.0)

1.18.0 (latest) 1.17.0 1.16.0 1.15.0 1.14.2 1.13.0 1.12.1 1.11.5 1.10.0 1.9.4 1.8.1 1.7.1 1.6.0 1.5.3 1.4.1 1.3.3 1.2.1 1.1.5 1.0.2 0.2.0 0.1.0

    UrlMap(mapping=None, *, ignore_unknown_fields=False, **kwargs)

URL pattern and description of how the URL should be handled.
App Engine can handle URLs by executing application code or by
serving static files uploaded with the version, such as images,
CSS, or JavaScript.

This message has `oneof`_ fields (mutually exclusive fields).
For each oneof, at most one member field can be set at the same time.
Setting any member of the oneof automatically clears all other
members.

.. _oneof: <https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields>

| ## Attributes ||
|---|---|
| **Name** | **Description** |
| `url_regex` | `str` URL prefix. Uses regular expression syntax, which means regexp special characters must be escaped, but should not contain groupings. All URLs that begin with this prefix are handled by this handler, using the portion of the URL after the prefix as part of the file path. |
| `static_files` | `https://docs.cloud.google.com/python/docs/reference/appengine/latest/google.cloud.appengine_admin_v1.types.StaticFilesHandler` Returns the contents of a file, such as an image, as the response. This field is a member of `oneof`_ `handler_type`. |
| `script` | `https://docs.cloud.google.com/python/docs/reference/appengine/latest/google.cloud.appengine_admin_v1.types.ScriptHandler` Executes a script to handle the requests that match this URL pattern. Only the `auto` value is supported for Node.js in the App Engine standard environment, for example `"script": "auto"`. This field is a member of `oneof`_ `handler_type`. |
| `api_endpoint` | `https://docs.cloud.google.com/python/docs/reference/appengine/latest/google.cloud.appengine_admin_v1.types.ApiEndpointHandler` Uses API Endpoints to handle requests. This field is a member of `oneof`_ `handler_type`. |
| `security_level` | `https://docs.cloud.google.com/python/docs/reference/appengine/latest/google.cloud.appengine_admin_v1.types.SecurityLevel` Security (HTTPS) enforcement for this URL. |
| `login` | `https://docs.cloud.google.com/python/docs/reference/appengine/latest/google.cloud.appengine_admin_v1.types.LoginRequirement` Level of login required to access this resource. Not supported for Node.js in the App Engine standard environment. |
| `auth_fail_action` | `https://docs.cloud.google.com/python/docs/reference/appengine/latest/google.cloud.appengine_admin_v1.types.AuthFailAction` Action to take when users access resources that require authentication. Defaults to `redirect`. |
| `redirect_http_response_code` | `https://docs.cloud.google.com/python/docs/reference/appengine/latest/google.cloud.appengine_admin_v1.types.UrlMap.RedirectHttpResponseCode` `30x` code to use when performing redirects for the `secure` field. Defaults to `302`. |

## Classes

### RedirectHttpResponseCode

    RedirectHttpResponseCode(value)

Redirect codes.