***

title: "Region"
generated: true
---------------

<GenerationInfo sourceFile="packages/core/src/entity/region/region.entity.ts" sourceLine="22" packageName="@vendure/core" />

A Region represents a geographical administrative unit, such as a Country, Province, State, Prefecture etc.
This is an abstract class which is extended by the [Country](/current/core/reference/typescript-api/entities/country#country) and [Province](/current/core/reference/typescript-api/entities/province#province) entities.
Regions can be grouped into [Zone](/current/core/reference/typescript-api/entities/zone#zone)s which are in turn used to determine applicable shipping and taxes for an [Order](/current/core/reference/typescript-api/entities/order#order).

```ts title="Signature"
class Region extends VendureEntity implements Translatable, HasCustomFields {
    @Column() code: string;
    @Column({ nullable: false, type: 'varchar' })
    readonly type: RegionType;
    name: LocaleString;
    @Index()
    @ManyToOne(type => Region, { nullable: true, onDelete: 'SET NULL' })
    parent?: Region;
    @EntityId({ nullable: true })
    parentId?: ID;
    @Column() enabled: boolean;
    @OneToMany(type => RegionTranslation, translation => translation.base, { eager: true })
    translations: Array<Translation<Region>>;
    @Column(type => CustomRegionFields)
    customFields: CustomRegionFields;
}
```

* Extends: [`VendureEntity`](/current/core/reference/typescript-api/entities/vendure-entity#vendureentity)

* Implements: [`Translatable`](/current/core/reference/typescript-api/entities/interfaces#translatable), HasCustomFields

<div className="members-wrapper">

### code

\<MemberInfo kind="property" type={`string`}   />

A code representing the region. The code format will depend on the type of region. For
example, a Country code will be a 2-letter ISO code, whereas a Province code could use
a format relevant to the type of province, e.g. a US state code like "CA".

### type

\<MemberInfo kind="property" type={`RegionType`}   />

### name

\<MemberInfo kind="property" type={`LocaleString`}   />

### parent

\<MemberInfo kind="property" type={`<a href='/current/core/reference/typescript-api/entities/region#region'>Region</a>`}   />

### parentId

\<MemberInfo kind="property" type={`<a href='/current/core/reference/typescript-api/common/id#id'>ID</a>`}   />

### enabled

\<MemberInfo kind="property" type={`boolean`}   />

### translations

\<MemberInfo kind="property" type={`Array<Translation<<a href='/current/core/reference/typescript-api/entities/region#region'>Region</a>>>`}   />

### customFields

\<MemberInfo kind="property" type={`CustomRegionFields`}   />

</div>
