---
schema_version: "1"
id: 3a69b81ac10de2ad523f7fd7e3edce484fd5114a65453def95b8962c21c2f14f
title: Types (dw::core::Types)
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/dataweave/2.6/dw-types.md
canonical_url: https://docs.mulesoft.com/dataweave/2.6/dw-types
source_site: docs.mulesoft.com
content_type: documentation
content_hash: e0a12dace94918088442df72d37071322bd12d3ab6cd64613c2fe0657e027c19
description: MuleSoft Documentation Site
release: "2.6"
latest: false
---
---
product: DataWeave
version: 2.6
---

# Types (dw::core::Types)

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

This module enables you to perform type introspection.

To use this module, you must import it to your DataWeave code, for example, by adding the line
`import * from dw::core::Types` to the header of your DataWeave script.

_Introduced in DataWeave version 2.3.0._

## Functions

<table><colgroup><col> <col></colgroup><thead><tr><th>Name</th><th>Description</th></tr></thead><tbody><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-arrayitem">arrayItem</a></p></td><td><p>Returns the type of the given array. This function fails if the input is not an Array type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-basetypeof">baseTypeOf</a></p></td><td><p>Returns an the base type of the given type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-functionparamtypes">functionParamTypes</a></p></td><td><p>Returns the list of parameters from the given function type. This function fails if the provided type is not a Function type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-functionreturntype">functionReturnType</a></p></td><td><p>Returns the type of a function’s return type. This function fails if the input type is not a Function type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-intersectionitems">intersectionItems</a></p></td><td><p>Returns an array of all the types that define a given Intersection type. This function fails if the input is not an Intersection type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isanytype">isAnyType</a></p></td><td><p>Returns <code>true</code> if the input is the Any type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isarraytype">isArrayType</a></p></td><td><p>Returns <code>true</code> if the input type is the Array type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isbinarytype">isBinaryType</a></p></td><td><p>Returns <code>true</code> if the input is the Binary type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isbooleantype">isBooleanType</a></p></td><td><p>Returns <code>true</code> if the input is the Boolean type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isdatetimetype">isDateTimeType</a></p></td><td><p>Returns <code>true</code> if the input is the DateTime type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isdatetype">isDateType</a></p></td><td><p>Returns <code>true</code> if the input is the Date type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isfunctiontype">isFunctionType</a></p></td><td><p>Returns <code>true</code> if the input is the Function type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isintersectiontype">isIntersectionType</a></p></td><td><p>Returns <code>true</code> if the input type is the Intersection type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-iskeytype">isKeyType</a></p></td><td><p>Returns <code>true</code> if the input is the Key type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isliteraltype">isLiteralType</a></p></td><td><p>Returns <code>true</code> if the input is the Literal type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-islocaldatetimetype">isLocalDateTimeType</a></p></td><td><p>Returns <code>true</code> if the input is the LocalDateTime type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-islocaltimetype">isLocalTimeType</a></p></td><td><p>Returns <code>true</code> if the input is the LocalTime type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isnamespacetype">isNamespaceType</a></p></td><td><p>Returns <code>true</code> if the input is the Namespace type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isnothingtype">isNothingType</a></p></td><td><p>Returns <code>true</code> if the input is the Nothing type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isnulltype">isNullType</a></p></td><td><p>Returns <code>true</code> if the input is the Null type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isnumbertype">isNumberType</a></p></td><td><p>Returns <code>true</code> if the input is the Number type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isobjecttype">isObjectType</a></p></td><td><p>Returns <code>true</code> if the input is the Object type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isperiodtype">isPeriodType</a></p></td><td><p>Returns <code>true</code> if the input is the Period type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-israngetype">isRangeType</a></p></td><td><p>Returns <code>true</code> if the input is the Range type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isreferencetype">isReferenceType</a></p></td><td><p>Returns <code>true</code> if the input type is a Reference type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isregextype">isRegexType</a></p></td><td><p>Returns <code>true</code> if the input is the Regex type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isstringtype">isStringType</a></p></td><td><p>Returns <code>true</code> if the input is the String type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-istimetype">isTimeType</a></p></td><td><p>Returns <code>true</code> if the input is the Time type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-istimezonetype">isTimeZoneType</a></p></td><td><p>Returns <code>true</code> if the input is the TimeZone type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-istypetype">isTypeType</a></p></td><td><p>Returns <code>true</code> if the input is the Type type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isuniontype">isUnionType</a></p></td><td><p>Returns <code>true</code> if the input type is the Union type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-isuritype">isUriType</a></p></td><td><p>Returns <code>true</code> if the input is the Uri type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-literalvalueof">literalValueOf</a></p></td><td><p>Returns the value of an input belongs to the Literal type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-metadataof">metadataOf</a></p></td><td><p>Returns metadata that is attached to the given type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-nameof">nameOf</a></p></td><td><p>Returns the name of the input type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-objectfields">objectFields</a></p></td><td><p>Returns the array of fields from the given Object type. This function fails if the type is not an Object type.</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/dataweave/2.6/dw-types-functions-unionitems">unionItems</a></p></td><td><p>Returns an array of all the types that define a given Union type. This function fails if the input is not a Union type.</p></td></tr></tbody></table>

## Types

- [Types Types](https://docs.mulesoft.com/dataweave/2.6/dw-types-types)
