---
title: TranslationSession.Request
framework: translation
role: symbol
role_heading: Structure
path: translation/translationsession/request
---

# TranslationSession.Request

A translation request containing a single item of text to translate.

## Declaration

```swift
struct Request
```

## Overview

Overview Create a translation request to translate a string of text. Initialize the request using init(sourceText:clientIdentifier:). Set the sourceText to the string of text you want to translate. Then pass that request in an array to one of the batch translation functions. Keep track of the correspondence between the responses and requests by setting the clientIdentifier on the sent request, then matching it with the clientIdentifier of the received response when the translation completes.

## Topics

### Initializing a translation request

- [init(sourceText:clientIdentifier:)](translation/translationsession/request/init(sourcetext:clientidentifier:)-8fung.md)
- [init(sourceText:clientIdentifier:)](translation/translationsession/request/init(sourcetext:clientidentifier:)-ruyz.md)

### Specifying text to translate

- [sourceText](translation/translationsession/request/sourcetext.md)
- [attributedSourceText](translation/translationsession/request/attributedsourcetext.md)

### Identifying requests

- [clientIdentifier](translation/translationsession/request/clientidentifier.md)

## See Also

### Translating the text

- [translate(_:)](translation/translationsession/translate(_:)-59zi2.md)
- [translate(_:)](translation/translationsession/translate(_:)-4m20l.md)
- [translate(batch:)](translation/translationsession/translate(batch:).md)
- [translations(from:)](translation/translationsession/translations(from:).md)
- [TranslationSession.Response](translation/translationsession/response.md)
- [TranslationSession.BatchResponse](translation/translationsession/batchresponse.md)
