[SPIGOT-6872] Add `v1_18` for `ApiVersion.Target` plugin annotations Created: 27/Dec/21  Updated: 27/Dec/21  Resolved: 27/Dec/21

Status: Resolved
Project: Spigot
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: New Feature Priority: Minor
Reporter: Patryk Ludwikowski Assignee: Unassigned
Resolution: Fixed Votes: 0
Labels: API, spigot

Version: This server is running Paper version git-Paper-19 (MC: 1.18) (Implementing API version 1.18-R0.1-SNAPSHOT) (Git: 892c292)
Guidelines Read: Yes

 Description   

Please add `v1_18` for `ApiVersion.Target` plugin annotations. Making constructor public would also be nice, in case anyone want to use some custom/new API version without waiting for update.

 

https://hub.spigotmc.org/stash/projects/SPIGOT/repos/plugin-annotations/browse/src/main/java/org/bukkit/plugin/java/annotation/plugin/ApiVersion.java

Example:
```java
@Plugin(name = "MyPlugin", version = "0.1")
@ApiVersion(ApiVersion.Target.v1_18) // Error, v1_18 does not exist currently :C
public class MyPlugin extends JavaPlugin
//...
```
 



 Comments   
Comment by Doc [ 27/Dec/21 ]

Currently have a PR for this. https://hub.spigotmc.org/stash/projects/SPIGOT/repos/plugin-annotations/pull-requests/9/overview

Comment by Phoenix616 [ 27/Dec/21 ]

> Making constructor public would also be nice

Just fyi: New Enums cannot be created at runtime so that wouldn't work.

Generated at Sat Dec 13 13:37:03 UTC 2025 using Jira 10.3.13#10030013-sha1:56dd970ae30ebfeda3a697d25be1f6388b68a422.