Debug API designer vs sublime


#1

I coded my api in API designer and it ran smoothly, no errors or anything.

I copy pasted my code into sublime and it gave me errors back.

In my examples.raml which is my trait file, I have

#examples.raml
- bn_token:
    headers:
      bn_token:
        description:
          The user's bn_token that is used to authenticate.
        type: string
        required: true
        example: number
        
            
- company_id:
    queryParameters:
      companyID:
        description:
          The CATM company ID.
        type: integer  
        required: true
        example: number.

The error it gives me back is the first line needs #%RAML 0.8 but after i inserted that it points to my bn_token and states “Error: document must be a map”

In my main file I have:
traits: !include examples.raml



#2

I think sublime get’s confused about the extension. Can you try to call it *.yaml instead of *.raml please.


#3

Works for me in Sublime 3… not the same colors as the Designer but same sort of format for coloring things. If only this could include code completion!


#4

Okay, I can call *.yaml. Apparenlty, even if it gives me a warning/error when I have it sublime, it does let me run and use the *.raml files.