# Interface CourseApi

#### See

Course REST API provides the following functions for use by plugins.

interface CourseApi {
activateRoute(dest: null | RouteDestination): Promise<void>;
clearDestination(): Promise<void>;
getCourse(): Promise<CourseInfo>;
setDestination(
dest:
| null
| (PointDestination & { arrivalCircle?: number | undefined; }),
): Promise<void>;
}

#### Hierarchy

- CourseApi
  - ServerAPI

- Defined in course.ts:7

##### Index

### Course API

activateRoute
clearDestination
getCourse
setDestination

## Course API

### activateRoute

- activateRoute(dest: null | RouteDestination): Promise<void>

  Follow a route in the specified direction and starting at the specified point.

  #### Parameters

  - dest: null | RouteDestination

    Object containing route information.

    - returns: Resolved Promise on success.

  #### Returns Promise<void>

  - Defined in course.ts:43

### clearDestination

- clearDestination(): Promise<void>

  Cancels navigation to the current point or route being followed.

  #### Returns Promise<void>

  - Defined in course.ts:20

### getCourse

- getCourse(): Promise<CourseInfo>

  Retrieves the current course information.

  #### Returns Promise<CourseInfo>

  - Defined in course.ts:13

### setDestination

- setDestination(
  dest:
  | null
  | (PointDestination & { arrivalCircle?: number | undefined; }),
  ): Promise<void>

  Set course to a specified position / waypoint.

  #### Parameters

  - dest: null | (PointDestination & { arrivalCircle?: number | undefined; })

    Object containing destination position information.

  #### Returns Promise<void>

  - Defined in course.ts:30