Skip to content

[Question] Each Operation API & API policy in each environment #732

@Setthawut-Peace

Description

@Setthawut-Peace

Release version

v6.0.1.4

Question Details

How to handle if i have a specific policy in each environment. Example

Operation API 001 - Policy [DEV]

<policies>
	<inbound>
		<base />
			<rewrite-uri template="/api/get/0010" copy-unmatched-params="true" />
	</inbound>
	<backend>
		<base />
	</backend>
	<outbound>
		<base />
	</outbound>
	<on-error>
		<base />
	</on-error>
</policies>

Operation API 001 - Policy [PRD]

<policies>
	<inbound>
		<base />
			<set-backend-service base-url="https://api.openweathermap.org/data/2.5/weather" />
			<rewrite-uri template="/api/" copy-unmatched-params="true" />
			<set-header name="x-rapidapi-key" exists-action="override">
				<value>abc1234</value>
			</set-header>
	</inbound>
	<backend>
		<base />
	</backend>
	<outbound>
		<base />
	</outbound>
	<on-error>
		<base />
	</on-error>
</policies>

Expected behavior

I need to using APIs & Operation APIs policy in each environment.

Actual behavior

Not able to find solution on how to override policy in each environment

Reproduction Steps

Not able to find solution on how to override policy in each environment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions